Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: [SOLVED] Unwanted parameter when executing CGI scripts

by Nocturnus (Sexton)
on Jan 07, 2013 at 08:36 UTC ( #1011975=note: print w/ replies, xml ) Need Help??


in reply to [SOLVED] Unwanted parameter when executing CGI scripts

Well, there is more misbehavior in CGI.pm. For example, if we call

/cgi-bin/script.pl?keywords=bla

then $q->url_param contains the key "keywords", but the respective value is empty. That means that you can't pass a parameter named "keywords" via query string if you use $q->url_param. The value of the "keywords" parameter will just be overwritten by CGI.pm.

Due to the problems mentioned in this thread, and due to the problem described above, I dumped CGI.pm and now parse the query string myself (with the help of uri_unescape). My code is now working like expected.

Regards,

Nocturnus


Comment on Re: [SOLVED] Unwanted parameter when executing CGI scripts
Download Code
Replies are listed 'Best First'.
Re^2: [SOLVED] Unwanted parameter when executing CGI scripts
by Anonymous Monk on Jan 07, 2013 at 09:14 UTC

    Well, there is more misbehavior in CGI.pm....

    Nope, wrong again.

    But I'm glad you've found a solution that works for you

      What exactly is wrong again?

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (6)
As of 2015-07-29 05:23 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (260 votes), past polls