ORCHARD PARK, N.Y. — It was a tough week for the Eagles defense.

It started with a horrible performance last Sunday night in Dallas, which came on the heels of an equally horrible performance the week before in Minneapolis.

Then, in between reading and hearing about how awful they were, there was Orlando Scandrick’s mud-slinging and the continuing saga of defensive captain Fletcher Cox’s love life.

"I’m just happy we stuck together through all the adversity this week," defensive end Brandon Graham said. "We made it about us.

"We said, ‘OK, the worst things came out about this team. So what’re we going to do about it?’ So we went out and we stayed together and we played together and we ended up getting a W."

Indeed they did.

As Graham will be the first to acknowledge, his much-maligned unit wasn’t perfect in the much-needed 31-13 win Sunday over the Bills.

Four times they let Josh Allen and the Bills offense escape from third-and-longs, including a pair of third-and-14s and a third-and-13. But, led by Graham and Cox, and bolstered by the return of cornerback Ronald Darby, the Eagles sacked Allen four times and held him to 5 yards per attempt.

And after giving up 311 rushing yards and 18 rushing first downs in those lopsided losses to the Vikings and Cowboys, they did a good job of holding the Bills’ seventh-ranked ground game in check.

They held Frank Gore to 34 yards on nine carries. And while Allen rushed for 45 yards on eight carries, Graham had a big momentum-shifting play in the second quarter when he poked the ball out of Allen’s arms on a third-and-2 keeper, and then also managed to recover it at the Buffalo 24-yard line.

The play set up a Carson Wentz-to-Dallas-Goedert touchdown pass that gave the Eagles a lead they never relinquished.

"That kind of sprung us forward," Graham said.

“We knew we were going up against a running quarterback,” said Cox. "When he did run, we tried to focus on getting it out.

"Brandon’s play was a tempo-setter for us. It took the life out of them early in the game."

It wasn’t the only big play the 10-year veteran made Sunday. He also notched his team-leading fifth sack of the season late in the third quarter.

With the Eagles up by 11, a muffed punt by Boston Scott gave the Bills the ball in Eagles territory. But on a third-and-8 at the Philadelphia 27, Graham sacked Allen for a 2-yard loss. Darby broke up a fourth-down pass for John Brown on the next play.

All five of Graham’s sacks this season have come on third down. On the first four, he lined up inside at tackle.

"I was outside on this one," said Graham. "I was at end but went inside when [Allen] tried to go through the B-gap."

For only the second time this season, the Eagles didn’t allow a score on their opponent’s first possession, forcing a three-and-out. Graham stopped Gore for no gain on the first play of the possession. Two plays later, on third-and-6, Cox picked up just his second sack of the season, beating Bills right guard Jon Feliciano.

"We started fast today," Cox said. "That was big. Everybody was to the ball.

"Looking back at the last few games, teams were coming out on their first drive and driving the ball down the field on us and were either getting three points or a touchdown.

"We just wanted to start fast. We’ve been talking about it all week. Stop killing ourselves, stop shooting ourselves in the foot. Play Eagle defense. Play Eagle football. I think we did that today."

The Bills went into the game with the league’s seventh-ranked ground game. The 36-year-old Gore was averaging 4.5 yards per carry. The 6-5, 237-pound Allen was averaging 4.2 yards per carry and had 13 rushing first downs on 45 carries. And slippery rookie Devin Singletary was averaging 9.0 yards per carry on 17 rushing attempts.

But the Eagles held Gore to 20 yards on seven carries in the first half, and Graham forced the game-shifting turnover from Allen.

"We had a chip on our shoulder today," Graham said. "We know we messed up the last two weeks. We knew what we had to do today. It wasn’t perfect. But we communicated well and got off the field."

Bruce Hector, who had been on the practice squad since the start of the season, was promoted last week and started next to Cox after Hassan Ridgeway became the latest defensive tackle to get hurt. Two other tackles with zero NFL game experience — Albert Huggins and Anthony Rush — also played Sunday.

"I knew today, with the younger guys coming in, I had to be the tempo-setter," Cox said. "I had to lead those guys, by far. At the end of the day, it came down to everybody doing their job.

"They played good. They played calm and didn’t make mistakes. The biggest thing I’ve been teaching those guys all week was get the call, get lined up, and go play football."

Graham said he was proud of the way the defense in particular and the team in general ignored all of the outside criticism and distractions last week and focused on the Bills.

"There was a lot of stuff that could’ve distracted us from the game," he said. "There’s a lot of things we could’ve been still trying to answer for.

"But we said, ‘Hey, it is what it is. All the stuff is out there. Now we got a clean slate. Everybody knows our stuff is whatever it is. So let’s go out there and change the way people view us.’

"We just want to go out there and get respect. As a defense, we didn’t play well last week or the week before. Some of it was just communication. Some of it was we didn’t make the plays when we were in position to make them.

Today, it wasn’t pretty sometimes, but we made the plays we needed to get off the field most of the time."

Eagles defensive end Brandon Graham (55) and teammates celebrate after he recovered a fumble during the second quarter.
TIM TAI / Staff Photographer
Eagles defensive end Brandon Graham (55) and teammates celebrate after he recovered a fumble during the second quarter.