in reply to Re: Re: Re: Dump a directory as links from CGI
in thread Dump a directory as links from CGI

The escaping of form parameters has different rules and cannot be done with a simple pass. You need to escape it by constructing a URI using URI. So, your example is bogus from the get-go.

In particular, what you want is:

$site = 'http://www.perlmonks.org/index.pl'; $user = 'Clive ;-)'; # my test case for whitespace and funny chrs use URI; my $uri = URI->new($site); $uri->query_form( node => $user ); print $uri->as_string;
which prints
http://www.perlmonks.org/index.pl?node=Clive+%3B-)

-- Randal L. Schwartz, Perl hacker

Replies are listed 'Best First'.
Re: Dump a directory as links from CGI
by cLive ;-) (Prior) on Jun 03, 2001 at 03:35 UTC
    Ooooo, fame at last :-))

    cLive ;-)