Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

x-www-form-urlencoded

by mldvx4 (Friar)
on Mar 21, 2018 at 20:13 UTC ( [id://1211453]=note: print w/replies, xml ) Need Help??


in reply to Re: What are best practices for Fast CGI nowadays?
in thread What are best practices for Fast CGI nowadays?

Ok, thanks. I've seen that and pretty much anything similar that can be found with Startpage.com. I can get the environment variables with FCGI no problem.

... HTTP_CONTENT_TYPE = application/x-www-form-urlencoded ...

I'm still left wondering how to get at the form data. I'd like the FCGI equivalent of ->params from old, slow CGI to get the idea behind FCGI.

use CGI; my $q = CGI->new; # Process an HTTP request my @values = $q->multi_param('form_field'); my $value2 = $q->param('param2_name');

It has to be Fast CGI because that is the API used by nginx and OpenBSD's httpd.

Replies are listed 'Best First'.
Re: x-www-form-urlencoded
by Anonymous Monk on Mar 21, 2018 at 22:02 UTC

    I'm still left wondering how to get at the form data.

    heh, use CGI ; its magic like that

      d'oh. That was what I was missing. CGI can be used with CGI::Fast.

      ... use CGI::Fast; use CGI qw(:standard); ...
        "d'oh..."

        BTW, how it was done in the past might be of interest.

        Best regards, Karl

        «The Crux of the Biscuit is the Apostrophe»

        perl -MCrypt::CBC -E 'say Crypt::CBC->new(-key=>'kgb',-cipher=>"Blowfish")->decrypt_hex($ENV{KARL});'Help

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1211453]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others romping around the Monastery: (5)
As of 2024-04-23 22:11 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found