Z
ziemon
// index.html
<a href="test.html?menu=menu1">menu1</a>
<a href="test.html?menu=menu1_1">menu1_1</a>
// index.html
// test.html
<html>
<head>
<title>Untitled</title>
<SCRIPT src="CSJSRequestObject.js" type=text/javascript></SCRIPT>
</head>
<body">
<SCRIPT type=text/javascript>
<!--
function player(number,name,position,height,college)
{
this.number = number
this.name = name
this.position = position
this.height = height
this.college = college
}
var menu1 = new Array(5)
menu1[0] = new player("20","Gary Payton","Guard"," 6'4","Oregon State")
var menu1_1 = new Array(2)
menu1_1[0] = new player("21","Pete Payton","Guard"," 6'4","Oregon State")
menu1_1[1] = new player("22","John Payton","Guard"," 6'4","Oregon State")
menu1[1] = new player("33","Hersey Hawkins","Guard"," 6'3","Bradley")
menu1[2] = new player("42","Vin Baker","Forward"," 6'11","Hartford")
menu1[3] = new player("11","Detlef Schrempf","Forward"," 6'10","
Washington")
menu1[4] = new player("22","Jim McIlvaine","Center"," 7'1"," Marquette")
var x = Request.QueryString("menu")
for (i = 0; i < x.length; i++)
{
document.write(x.number + x.name + x.height + x.position +
x.college + "<br>")
}
// -->
</script>
</body>
</html>
// test.html
y isn;t it working ?
if i do a check like :
if(x = "menu1")
{
alert("ok")
}
it shows its there
additional info about CSJSRequestObject.js can be found :
http://www.andrewu.co.uk/tools/request/
<a href="test.html?menu=menu1">menu1</a>
<a href="test.html?menu=menu1_1">menu1_1</a>
// index.html
// test.html
<html>
<head>
<title>Untitled</title>
<SCRIPT src="CSJSRequestObject.js" type=text/javascript></SCRIPT>
</head>
<body">
<SCRIPT type=text/javascript>
<!--
function player(number,name,position,height,college)
{
this.number = number
this.name = name
this.position = position
this.height = height
this.college = college
}
var menu1 = new Array(5)
menu1[0] = new player("20","Gary Payton","Guard"," 6'4","Oregon State")
var menu1_1 = new Array(2)
menu1_1[0] = new player("21","Pete Payton","Guard"," 6'4","Oregon State")
menu1_1[1] = new player("22","John Payton","Guard"," 6'4","Oregon State")
menu1[1] = new player("33","Hersey Hawkins","Guard"," 6'3","Bradley")
menu1[2] = new player("42","Vin Baker","Forward"," 6'11","Hartford")
menu1[3] = new player("11","Detlef Schrempf","Forward"," 6'10","
Washington")
menu1[4] = new player("22","Jim McIlvaine","Center"," 7'1"," Marquette")
var x = Request.QueryString("menu")
for (i = 0; i < x.length; i++)
{
document.write(x.number + x.name + x.height + x.position +
x.college + "<br>")
}
// -->
</script>
</body>
</html>
// test.html
y isn;t it working ?
if i do a check like :
if(x = "menu1")
{
alert("ok")
}
it shows its there
additional info about CSJSRequestObject.js can be found :
http://www.andrewu.co.uk/tools/request/