By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,679 Members | 1,592 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,679 IT Pros & Developers. It's quick & easy.

Help with split/Formmail.pl

P: n/a
Hello,

I have software that allows direct submission of tech support requests.
The software connect directly to a formmail script. The problem is that
if the user types a '=' or a '&' anywhere in the message, the resulting
email is truncated at that spot.

It looks like the sub parse_form routine, which splits on '&', is
responsible. Then again, submitting the same text from a web form (to
the same formmail.pl) does not truncate the text.

I submit the text in the form:

&recipient=the_recipient
&subject=the_subject
&=the_actual_message

Again, the_actual_message is clipped at first occurence of a '&' or
'='.
Any ideas how to fix this?

Kurt

Jul 19 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Kurt wrote:
I have software that allows direct submission of tech support
requests. The software connect directly to a formmail script. The
problem is that if the user types a '=' or a '&' anywhere in the
message, the resulting email is truncated at that spot.

It looks like the sub parse_form routine, which splits on '&', is
responsible.
Whichever formmail script it is you are using, it reasonably
presupposes that the incoming data is URI escaped, while the data you
are transferring from that other software is apparently not URI escaped.
Any ideas how to fix this?


Escape the data before passing it to formmail. See the URI::Escape module.

--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl

Jul 19 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.