467,887 Members | 1,550 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 467,887 developers. It's quick & easy.

Old issue: Hiding Javascript

Hello All,

I've read a lot of stuff which says it's impossible to hide Javascript, so if I get my PHP script to return some Javascript inside some XML using AJAX, how can it be viewed in the browser?

Obviously, some essential Javascript has to be there at the outset, ie. that which handles the AJAX, so you can't hide that, but if you then use AJAX to supply ad hoc Javascript on demand, can it be seen anywhere?

Your technical observations are most appreciated. Thanks for your time and attention.

Regards.
Dec 22 '09 #1
  • viewed: 1158
Share:
3 Replies
acoder
Expert Mod 8TB
Yes. Try, for example, Firebug (Firefox add-on).
Dec 22 '09 #2
Hey, thanks! Firebug is cool.
Dec 23 '09 #3
rnd me
Expert 256MB
ajax uses the same URLs that can be viewed in a browser by placing them in the address bar.

the only way you can hide is with ciphering. here's an app i made that can encode a whole webpage, javascript and all. But, your visitors would need to know the password to view it...

using something like dean edward's packer makes the code look like gibberish, but it's still easy for developers to "roll back" to the real code.

In short, javascript must eventually be delivered to the javascript engine as plain-text code.
that makes it impossible to truly use code without being able (perhaps with difficulty) for humans to read the code.
Dec 23 '09 #4

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

8 posts views Thread by Pjotr Wedersteers | last post: by
4 posts views Thread by web_design | last post: by
22 posts views Thread by Mr Newbie | last post: by
5 posts views Thread by skarnath | last post: by
24 posts views Thread by Kourosh | last post: by
11 posts views Thread by mike_solomon | last post: by
reply views Thread by Frank | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.