Building JavaScript source via PHP
| From: | Jan Walter | Date: | Wed, 31 Jan 2001 20:26:11 +0000 |
| Subject: | Building JavaScript source via PHP | ||
| Groups: | php.windows | ||
| Request: | Send a blank email to php-windows+get-5294@lists.php.net to get a copy of this message | ||
Dear PHP devoteees,
I have the following, very strange problem:
I use PHP to generate JavaScript source for
<script language="JavaScript" src="http://host/script.php"
type="text/javascript"></script>
but anytime an error in Netscape Navigator occurs (IE works properly):
--------------------
illegal character.
9
.^
--------------------
Even if script contains only:
document.write('Some text');
If I rename script.php to script.js, everything is OK. And the last
strange thing: this happens only on my web host's server, when I write
the code at home, everything is ok. Do you thing, apache+php send some
weird characters at the beginning of the page Netscape does not
recognize?
Thanx for any hint
--
__________________________________________________________________________________________
==========================================================================================
Jan Walter, called John
LERACH, s.r.o.
phone nr. work: +420-2-78 22 619, home: +420-2-35 35 27 61
on emergency call cell phone: +420-602-385 760
work e-mail mailto:Jan.Walter@lerach.cz
private e-mail mailto:john@lerach.cz
ICQ#: 28353428
__________________________________________________________________________________________
==========================================================================================