Newcastle came back from a goal down to claim a vital away win in their Uefa Cup tie against Heerenveen.
The home side took the lead after 24 minutes when Klaas-Jan Huntelaar fired in an unstoppable left-foot shot.
Newcastle responded well in the second half and skipper Alan Shearer's fine finish into the right-hand corner levelled the scores.
Lee Bowyer's flick put Newcastle ahead with eight minutes to go before he was sent off for a second yellow card.
The visitors, fresh from their trip to Dubai, were able to select Jermaine Jenas despite the midfielder having to pull out of training on Wednesday.
And the Magpies were the better side in the scrappy opening exchanges, although they were unable to carve out clear-cut chances.
The closest they came was from skipper Shearer, who forced Tomasz Rzasa into a fourth-minute block.
Heerenveen did not offer a lot early on, but striker Huntelaar caught the eye with some deft touches and it was his piece of brilliance that broke the deadlock.
Newcastle defender Titus Bramble failed to deal with a through ball and Arnold Bruggink fed Hunterlaar who turned superbly in the box before unleashing a bullet of a left-foot off the bar and into the net.
The home side almost added another two minutes later but Hunterlaar could not get any power on a superb cross.
There was plenty of huff and puff from the visitors but no end product and with five minutes of the first half left, Shola Ameobi created space on the left but his inviting cross flashed across the face of goal.
Manager Graeme Souness undoubtedly read the riot act at half-time and his side came out brightly with Stephen Carr firing in a cross that forced Heerenveen to clear.
The home side were next to create but Bruggink's drive from Bramble's clearance went over.
With the travelling Magpies fans making their frustrations known, Souness needed his side to respond and that they did with Bowyer and Ameobi creating chances.
To try and swing the tie in his favour, Souness brought on creative winger Laurent Robert with 28 minutes to go and the change of system paid dividends almost immediately.
On 66 minutes, Robert fed the more advanced Patrick Kluivert who instantly played in Shearer and the former England captain finished emphatically.
Newcastle piled forward for the winner and it came with eight minutes left when Carr's cross was cheekily flicked in to the far corner by Bowyer.
But Heerenveen almost left with the draw after another mistake from Bramble gave Mika Vayrynen a free run in on goal but Given produced a superb stop.
Bowyer then saw his night end on a low note when he saw red with four minutes to go after receiving a second yellow card for deliberate handball.
Heerenveen: Vandenbussche, Bakkati, Hansson, Breuer, Rzasa, Vayrynen, Hestad, Huntelaar (Samaras 78), Prager (Rose 89), Bruggink (Sikora 79), Yildirim.
Subs Not Used: Waterman, Haarala, Wolfgang, Jeroen Drost.
Goals: Huntelaar 24.
Newcastle: Given, Carr, Andrew O'Brien, Bramble, Faye, Babayaro (Hughes 52), Bowyer, Jenas, Kluivert, Ameobi (Robert 62), Shearer (Taylor 89).
Subs Not Used: Caig, N'Zogbia, Milner, Ambrose.
Sent Off: Bowyer (86).
Booked: Bowyer, Ameobi, Jenas.
Goals: Shearer 69, Bowyer 82.
Ref: Zsolt Szabo (Hungary).