use strict; use URI::Escape: use LWP:Simple; my $res = get("http://www.foo.com?data=".uri_escape("12 34+56")); #sent as: data=12%2034%2B12, both space and "+" are escaped. my $res2 = get("http://www.foo.com?data=12 34+56")); # sent as: date=12%2034+56, i.e. space is escaped, but "+" is not. #### # in URI::_init(C:/Perl/site/lib/URI.pm:76): $str =~ s/([^$uric\#])/$URI::Escape::escapes{$1}/go; # where $uric is: # \;\/\?\:\@\&\=\+\$\,\[\]A-Za-z0-9\-_\.\!\~\*\'\(\)% #### $text =~ s/([^A-Za-z0-9\-_.!~*'()])/$escapes{$1}/g;