"Damned the Torpedoes, Full Speed Ahead!" is an apocryphal
phrase said to be uttered by Rear Admiral David G Farragut of the
US Navy, during the Battle of Mobile in the American Civil War,
August 5, 1864.
It is most likely that Farragut actually said "Damn the
Torpedoes, Four Bells, Captain Drayton!" (the commander of the ship
he was on). He likely shouted to the captain of the nearest Union
ship: "Go ahead, Jouett, Full Speed!" The two phrases have become
united in common memory now, into the single phrase above.
In the context of the time "Torpedo" was what we now refer to as
a "naval mine", not the self-propelled anti-ship weapon of today.
So, more accurately for today's audience, Farragut was stating:
"Ignore the minefield, press on at full speed!" He said this as
part of his invading fleet was slowed due to one of the ships
hitting a previously unknown mine; Farragut was hoping to press the
attack into Mobile Bay quickly, so as to flank the shore batteries.
He was successful, and the Union won the battle.
In a modern context, "Damn the Torpedoes!" is usually meant as
"forget any problems we're having, press onward!" That is, ignore
the problems you might be experiencing, under the assumption that
you can complete the task anyway, after which those problems become
irrelevant.