in reply to uri and file names

Use URI::Escape to escape the filenames. "boo%20hoo.xls" becomes "boo%2520hoo.xls".

Anno

Update: Pointer to URI::Escape added.