Re: Server Side Include and Document Write problem...
by Andrew McFarland <aamcf(at)aamcf.co.uk>
|
Date: |
Wed, 22 May 2002 21:58:41 +0100 |
To: |
hwg-languages(at)hwg.org |
In-Reply-To: |
hotmail |
|
todo: View
Thread,
Original
|
|
At 15:17 22/05/02 -0400, Michael Boyer wrote:
<snip/>
>var include= "<!--#include file='" +dayMonth + ".txt' -->";
<snip/>
All server side includes are processed before the server sends the page to
the browser. All JavaScript is processed by the browser after it receives
the page from the server.[1]
You are trying to insert a JavaScript variable into an SSI statement.
However, the JavaScript isn't interpreted until it reaches the browser,
which is after all SSI processing is done and dusted. Probably the best
thing to do is to build an array of the strings you want in an external
JavaScript file.
Andrew
--
http://aamcf.co.uk/
[1] Yes, you can have server site JavaScript, but it isn't used here.
HWG: hwg-languages mailing list archives,
maintained by Webmasters @ IWA