in reply to Re^5: globbed variable in parse cgi form - beyond me
in thread globbed variable in parse cgi form - beyond me
Ah - then I just misunderstood your first post of
... if you want things fast and easy ...
as "fast and easy to learn", instead of an invitation to look at other approaches.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^7: globbed variable in parse cgi form - beyond me
by Don Coyote (Hermit) on Jun 30, 2011 at 16:37 UTC | |
I have taken 'cgi' in now and can use it to produce a basic site in HTML. The DTD does have it's own paramater in the start_html function/method. So I was able to explicitly define the document type to that of one with which I am familiar. The issue of the multiline text newline remains. After making a workaround, I think the correct way to access the value for a textarea is to dereference the hash containing the postdata directly and manipulate the strings accordingly. Back to square one, that is currently beyond my skills. CGI appears to be helpful by removing the hardcoded return newline/carriage returns. Either this or it is an encoding issue, and the header encoding is constructed incorrectly in my script so the browser interprets it incorrectly for html. Or a mixture of the two. Workaround: Send textarea value to datafile readit back in as an array of lines, chop the \r and \n off and join with p tags. may be issues with using chop here. But for the moment returns the multiline in a multiline format. (pls dont tell me I can use sprintf here I will go bonkers!) so:returns to the html and therefore the browser instead of returning a text encoded format to the html but not the browser.
I will need to look a little more into encoding types . For quick and easy I found 'Impatient Perl' by Greg London to be a great quick reference for syntax and structures. Thanks for all help on this, CGI is actually a pretty neat module once you've learnt to use it. Don C | [reply] [d/l] [select] |