------------------------------------------------------------------------------- WWW Data Conversions URL-escape perl -MURI::Escape -le 'print uri_escape($string)' URI-unescape perl -MURI::Escape -le 'print uri_unescape($string)' HTML Encode string perl -MHTML::Entities -le 'print encode_entities($string)' HTML Decode perl -MHTML::Entities -le 'print decode_entities($string)' File URI to file path (unescape) uri='file:///...' file=`perl -e '$_='"'$text_uri'"'; s%^[a-z]+://%%; s/\%([A-Fa-f0-9._-]{2})/pack("C", hex($1))/seg; print;' ` NOTE: Scripts should also look for and reject '..' or other bad behaviour. -------------------------------------------------------------------------------