better use of URI.encode