
three-part form submission using CGI.pm
[jeopardectomy performed]
| Make a bunch of hidden fields for the information in the 2nd form doing
| this.
|
| foreach $param (param){$hiddeninfo .= hidden($param)."\n";}
|
| Then on your 3rd submission you will have the same field names and
| stuff you need.
|
| B. Carlson
it seems to me that if I have to do it this way, that a map would be
more efficient.
I don't quite grok the map function yet (although I can definitely feel
the need to) .. I'm going to take a whack at this right here off the top
of my head, and invite some critique from you more experienced map-ers
print header, start_html, start_form,
( map {
hidden({-name=>$_, -Values=>unescapeHTML(param($_))})
} (param)
),
submit(), end_form, end_html;
I tried this, and played with it a bit, and it otherwise seems to work
fine, but it introduces another problem..
I have some textarea fields that I want the users to be able to input in
paragraph format and preserve the line breaks (for which I was using a
fix_paragraphs() sub that replaces all the \n's with <br>'s instead)
however when I view the 'intermediate preview', all the \n's are
HTML-escaped by CGI.pm to be pairs (and I'm not even sure
whether this is localized to being on a Mac, or if that's normal.)
I've tried adding those to the fix_paragraphs sub in a separate regex
but it's not catching them. any suggestions on this?
--
send mail to webmaster (at) webdragon (dot) net instead of the above address.
this is to prevent spamming. e-mail reply-to's have been altered
to prevent scan software from extracting my address for the purpose
of spamming me, which I hate with a passion bordering on obsession.