[PHP] How to protect JavaScript?

2002-01-16 Thread Martin Thoma
Hello! I want to protect a JavaScript: It should only be readable out of the document, where it is included (with script language=javascript src=/myjs.js). But it should not be possible to read it directly with www.myserver.de/myjs.js. I thought I could do this with PHP (f.e. check the

RE: [PHP] How to protect JavaScript?

2002-01-16 Thread Bart Brinkmann
/bart -Original Message- From: Martin Thoma [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 16, 2002 9:29 AM To: [EMAIL PROTECTED] Subject: [PHP] How to protect JavaScript? Hello! I want to protect a JavaScript: It should only be readable out of the document, where it is included

Re: [PHP] How to protect JavaScript?

2002-01-16 Thread Martin Thoma
Hi Bart, I think it's the same problem as with php: You could only protect it, when a HTTP_REFERRER is send (which Netscape does not do): Description: Assume we have under http://www.quux-corp.de/~quux/ some pages with inlined GIF graphics. These graphics are nice, so others directly

RE: [PHP] How to protect JavaScript?

2002-01-16 Thread Bart Brinkmann
the primer above, it's pretty straght-forward. /bart -Original Message- From: Martin Thoma [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 16, 2002 9:47 AM To: [EMAIL PROTECTED] Subject: Re: [PHP] How to protect JavaScript? Hi Bart, thanx for your answer. This would only be true

Re: [PHP] How to protect JavaScript?

2002-01-16 Thread Martin Thoma
Hi Bart, thanx for your answer. This would only be true if your javascript files were parsed with php.If not, then php can't do anything about it of course. This is possible, I tried it out. Look into mod_rewrite. I haven't used it in the sense that you're looking for, but I don't see why