UnPHP: A free online service to decode obfuscated PHP code. A good chance to solve your issue.
PHP Decoder: The same as above and still useful (if UnPHP was not successful).
Eval base64_decode: also useful for PHP code

For JavaScript

Script Asylum: A good tool for escaping/encoding text, HTML or JavaScript.

Base64: HEX encode/decode