Is there a better way to reset CGI object for AJAX POSTDATA?
- From: Dodger <el.dodgero@xxxxxxxxx>
- Date: Fri, 21 Dec 2007 15:10:53 -0800 (PST)
Currently I'm doing this:
use CGI();
my $cgi = new CGI;
$cgi = new CGI($cgi->param('POSTDATA'));
.... in order to get the data an XMLHTTPRequest object sends through on
a POST request, because everything goes under the POSTDATA param as a
query string. AND can I just say... Yuck!
Anyway, my solution seems kludgy and I don't like it. It smells funny.
CGI.pm docs mention a class method restore_parameters() that works
like so:
open (IN,"test.in") || die;
restore_parameters(IN);
close IN;
....but there's no other mention of it, and no mention of an object
method. I can't stand using the functional interface for CGI.pm.
Isn't there any way to just reset an existing CGI object directly
without calling the constructor all over again?
--
Sean 'Dodger' Cannon
.
- Follow-Ups:
- Prev by Date: Re: Question to Sisyphus
- Next by Date: Re: Is there a better way to reset CGI object for AJAX POSTDATA?
- Previous by thread: Question to Sisyphus
- Next by thread: Re: Is there a better way to reset CGI object for AJAX POSTDATA?
- Index(es):
Relevant Pages
|
|