Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??

Well, it might make sense, but it's not what I want. As I wrote above, the problem arose when I was trying to pass parameters from the query string to another script by constructing a link which contains these parameters. I used the following method (pseudocode):

In scriptA.pl, fill hash with all parameters from query string, using $q->url_param (and not $q->param) Do something with the hash entries Construct a new query string from the hash entries Generate a link to scriptB.pl?<new query string>

Now, I if call

/cgi-bin/scriptA.pl

(without any parameters), the resulting link is

/cgi-bin/scriptB.pl?keywords=

i.e. there is an empty parameter "keywords" in the link which should not be there.

This was not acceptable for me. Solving that problem turned out not to be too easy because I wanted to keep the "keywords" parameter if it had been in the query string in the first place.

See my post below for additional misbehavior of CGI.pm and for how I solved the problem.

Regards,

Nocturnus


In reply to Re^6: Unwanted parameter when executing CGI scripts by Nocturnus
in thread [SOLVED] Unwanted parameter when executing CGI scripts by Nocturnus

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having a coffee break in the Monastery: (3)
As of 2024-04-18 23:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found