gregreeve
asked on
Single comments causing runtime problems
I have a form that calls a perl script. When the user enters a single comment character it causes my perl script to blow up when I try printing that field. So my code looks like:
$comment= $query->param('comment');
and later on
print $comment;
I know it must be sonething simple - any ideas?
$comment= $query->param('comment');
and later on
print $comment;
I know it must be sonething simple - any ideas?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
its the perl script that complains about there being a non terminated single quote.
ASKER
sorry - I need to be clearer.
I am accepting input, printing it to the mailer (sending mail) and then I print a 'Location:http//.....' at the end to send the user to a web page.
I will try the Content-type though...
Greg
I am accepting input, printing it to the mailer (sending mail) and then I print a 'Location:http//.....' at the end to send the user to a web page.
I will try the Content-type though...
Greg
ASKER
Thanks - my mistake was to put the $comment in quotes before as a part of the print string. Now it works fine.
Many Thanks - enjoy your points!
Many Thanks - enjoy your points!
Glad to have been of help to you :-)
Rgds
Rgds
How did putting $comment in quotes cause a problem?
In what way does it blow up?