Links

Lists

Latest Updates

Ruby On Rails List
Python list
Advanced Java
The JavaScript List
Apache Users
Full Disclosure
Linux Security

Search the archives!


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Javascript] Include Problem


  • From: javascript@xxxxxxxxxx (Jason Belanger)
  • Subject: [Javascript] Include Problem
  • Date: Fri, 26 Oct 2001 11:23:16 -0400

Hi Howard,

You cannot have dynamic includes in your pages either by way of JavaScript =
or ASP. The include section gets processed by the server before you even =
get the page. There is a way to do it but I suggest you look into the ASP =
ListServ:

http://list.15seconds.com/scripts/lyris.pl?enter=3Dactiveserverpages&text_m=
ode=3D0

Watch for the wrap.

Jason

Jason Belanger
Web Technologies System Specialist
(613) 759-7809
belangerj@xxxxxxxxx
http://www.agr.ca/

>>> HowardSalter@xxxxxxxxxxxxxxxxxx 10/26/01 11:22AM >>>
I've been beating my head against a wall trying to figure out why I can't
make an include work, so now I'm going to ask you all.

I've got a place in the middle of my asp page where I include another ASP
page. I want to determine from the query string (I already have a query
string parsing function) which asp file I want to include. My problem is,
that after the --> in my include everything becomes plain text. Here's an
example of the code:

if QueryString("cond") =3D "CONDITION1"
	{
		document.write ("<!-- #Include File=3D'include1.asp' =
-->");
	}
else if QueryString("cond") =3D "CONDITION2"
	{
		document.write ("<!-- #Include File=3D'include2.asp' =
-->");

	}

Beware the wrap.

TIA,
Howard
_______________________________________________
Javascript mailing list
Javascript@xxxxxxxxxx=20
http://www.LaTech.edu/mailman/listinfo/javascript