Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: ModPerl: ModPerl

How to tell GET from POST method ni CGI.pm?

 

 

ModPerl modperl RSS feed   Index | Next | Previous | View Threaded


ichudov at gmail

May 15, 2011, 8:02 AM

Post #1 of 2 (547 views)
Permalink
How to tell GET from POST method ni CGI.pm?

I am beginning to work on hardening my website against cross site request
forgeries. I use CGI.pm.

My question is, how can I tell, using CGI.pm, if this webpage was invoked
with a GET or POST method?

Thanks


randolf at modperl

May 15, 2011, 10:03 AM

Post #2 of 2 (525 views)
Permalink
Re: How to tell GET from POST method ni CGI.pm? [In reply to]

> I am beginning to work on hardening my website against cross site request
> forgeries. I use CGI.pm.
>
> My question is, how can I tell, using CGI.pm, if this webpage was invoked
> with a GET or POST method?

You're probably intersted in: $q->request_method

It should also be available in an environment variable of the same
name: $ENV{'REQUEST_METHOD'}

Randolf Richardson - randolf [at] inter-corporate
Inter-Corporate Computer & Network Services, Inc.
Vancouver, British Columbia, Canada
http://www.inter-corporate.com

ModPerl modperl RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.