Mark Aston’s Eagles beat League One side Doncaster 32-28.
Doncaster took the lead with a Sam Doherty converted try, before the Eagles went 12-6 up with tries from Jacob Ogden and Rory Dixon, both converted by Pat Walker.
Tries from Jez Litten (2) and Beharrell, plus two penalties via Beharrell, saw Dons pull ahead at 28-12.
But tries from Ryan Millar, Josh Guzdek, Jason Crookes and Anthony Thackeray saw the Eagles battle back to win.
Batley snatched an extra-time winner with a Louis Joufrett drop goal to beat York City Knights 17-16.
York took an early lead with a Connor Robinson try, before Batley Bulldogs’ Jonny Campbell’s touchdown made it 6-6 at the interval.
Robinson’s penalty edged York in front, before tries from Sam Wood and Joufrett made it 16-8.
But York forced extra time with a Will Jubb try and a Robinson penalty.
Dewsbury Rams suffered a quarter-final defeat, losing 54-6 to Widnes Vikings.
Daniel Waite-Pullan - on loan from Leeds Rhinso - grabbed a late Rams try, after Paul Sykes had kicked an early penalty, but Anthony Gelling and Lloyd Roby grabbed hat-tricks for Widnes who ran in 10 tries.