in reply to URL Escaping

The function uri_escape takes an optional second argument that's a list of all characters that you want to encode. The following should work for you:
#!/usr/bin/perl -w use strict; use URI::Escape; my $cgi_chars = '\x00-\x29\x2b\x2c\x2f\x3a-\x40\x5b-\x5e\x60\x7b-\xff +'; my $bad_chars = '^%$&='; print uri_escape( $bad_chars, $cgi_chars );

Cheers,
Ovid

Join the Perlmonks Setiathome Group or just click on the the link and check out our stats.