sub uri_unescape { my $str=shift @_; $str=~s/%(\w{2})/chr(hex($1))/ge; return $str; }