Friday, January 14, 2005
I'm ready to run screaming towards the hills
I'm attempting to debug the shopping cart from hell. I finally got rid of the warnings, and the script is generating the following:
Set-Cookie: shopper_id=91548; path=/;
Content-type: text/html
<HTML>
…
But Apache still
doesnt' like it. I poke around and fine a test.pl
script:
#!/usr/bin/perl print "Hello world\n";
Okay. I can build on this, adding stuff to see what Apache might be
complaing about. I run this script from the command line and get “:
bad interpreter: No such file or directory
”.
Excuse me?
# which perl /usr/bin/perl # more test.pl #!/usr/bin/perl print "Hello world\n";
Huh?
I write my own version of this:
#!/usr/bin/perl print "Hello world\n";
And it worked.
Okay, probably some invisible character in test.pl
that's
giving the perl interpreter fits. Delete #!/usr/bin/perl
and
retype it.
: bad interpreter: No such file or directory
Much mucking around later (and remember, this is a side trek from what
I'm supposed to be doing—debugging some comercial perl script) I find out
that not only is test.pl
in the Microsoft text format,
but that the version of vi
(vi!
) I'm using
is “smart” enough to deal with the Microsoft text format and keep the
file in that format!
XXXX this, I'm going home.