Beefy Boxes and Bandwidth Generously Provided by pair Networks httptech
Just another Perl shrine
 
PerlMonks  

Re: Perl/CGI - passing AoH from one page to another

by ickyb0d (Monk)
on Nov 14, 2005 at 11:05 UTC ( [id://508334]=note: print w/replies, xml ) Need Help??

This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.


in reply to Perl/CGI - passing AoH from one page to another

Could store it in javascript object. Set a hidden field to the 'string' value of javascript object upon submission. Then use the JSON module to interpret it in the CGI script. json.org might give you some more insight into this as well.
  • Comment on Re: Perl/CGI - passing AoH from one page to another

Replies are listed 'Best First'.
Re^2: Perl/CGI - passing AoH from one page to another
by dorward (Curate) on Nov 14, 2005 at 11:13 UTC

    Converting to JSON would be one technique you could use for serializing the data. I wouldn't have thought you would need to pass it though JavaScript though, that would put extra processing requirements on the client and break if JS was, for some reason, not available. You should be able to simply drop the JSON string into the hidden input (after encoding any characters that need to be represented by entities with HTML::Entities).

    See my previous comments about GET length and the suitability of POST though.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://508334]
help
Sections?
Information?
Find Nodes?
Leftovers?
    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.