in reply to How can I create a file named "default.asp?11=1"?
\/:*?"<>|append % to the beginning of the encoded char and also encode the % char.
Or you can use ord instead of unpack.my $name = "abba?@fzabb=11'a" $name =~ s/([\\\/:\*\?"<>\|])/\%unpack('H*', $1)/g; # name is now: abba%3f@fzabb=11'a%22
|
|---|