in reply to Parsing "&" from header.

I would normally do this as:
use CGI::Simple; my $q = CGI::Simple->new; my %input = $q->Vars; print $q->unescapeHTML( $input{'app_name'} );
The 1st line loads up the CGI::Simple module,
the 2nd line creates a new CGI::Simple object,
the 3rd line creates a hash containing all input sent to the CGI script (POST and GET),
the 4th line passes the $input{app_name'} value to the CGI::Simple's object method unescapeHTML.
That is necessary because any '&'s sent to your program will already have been HTML-encoded and will no longer be plain '&'s.

See CGI::Simple for more info.

Replies are listed 'Best First'.
Re: Re: Parsing "&" from header.
by Anonymous Monk on Mar 26, 2004 at 14:04 UTC
    Still cuts the results at the "&" or in the case of the first code it is printing the resuls but it is not printing the & back to the browser.
    Like:
    If I am seding Father&Sons
    Comes back
    FatherSons
    Any more sujestions?

      That's strange indeed. How does the <form>-tag look like?
      Maybe you need to write it like this:

      <form ... enctype="application/x-www-form-urlencoded">