in reply to Unescaping function
Here is essentially what that module would do, and how you can do the same without it.
# To encode $string =~ s/([^a-zA-Z0-9_\-.])/uc sprintf("%%%02x",ord($1))/eg; # To decode $string =~ s/%([0-9A-Fa-f]{2})/chr(hex($1))/eg;
It is always nice to know how stuff works, but it is almost always
better to still use the already thought through, (hopefully mostly debugged :-))
solutions found in the modules on CPAN.
Wonko
|
|---|