$ENV{'SCRIPT_FILENAME'}
and some regex wizardry always works for me!
-2 votes May I ask why? Maybe I'll learn something too.
Update: For those of you arriving at my node via a search please note it is NOT the right answer, see rest of thread
Thanks for the enlightenment Joost and Anon! Indeed something learned!