Hi! Thanks for responding.
I wanted to use JS for ASP. I am a beginner in JS and ASP. I can here
because I needed to know JS.
I have narrowed it down bit more as I have being reading all day but I am
still of coarse shaky, so please bare with me.
Here's where I am at now. I am testing this page.. and please tell me where
I am going wrong.
If you view this page the var ifp gets written out on screen ( so its not
empty ) but it does not work in the Request.Query and I don't know why.
this is really puzzling me. I have being at this all day. I know its a
string as Its being displayed on screen. and Request.QueryString works when
I pass the value from another page. why does it not accept the value that I
have declared?
<%@LANGUAGE="JAVASCRIPT" CODEPAGE="1252"%>
<html>
<head>
<title>Test Page</title>
<script language="JavaScript">
var
ifp="http://www.webcandesign.com/Without_fl/html/Premium_Templates_test.asp?ifp=http://office.microsoft.com/en-us/default.aspx";
if (typeof(ifp) == "undefined"){
document.write ("Type of x is undefined");}
else{
document.write (ifp);}
</script>
</head>
</html>
<body>
<iframe src="<%=Request.QueryString("ifp")%>" name="Iframe001"
width="750px" height="920px" scrolling="yes" id="Iframe001">If you are
reading this then your browser cannot view Iframe, Please upgrade you
browser. </iframe>
</body>
</html>
Ps. I hope I did not come off being rude before by using Capitals letters, I
sometimes use it to point out things so that it does not get overlooked. I
will try to keep away from using that method :)
Paul
"ASM" <st*********************@wanadoo.fr.invalid> wrote in message
news:42***********************@news.wanadoo.fr...
Paul wrote: Hi! and thanks for responding. basically I have a menu with sub-menu
options which are htm file to go into an iframe.
sub-menu by options from a select ?
because if it is by JS, basicaly,
the main menu must send a page with sub-menus linked in it
I need it to be so I can do this from any page in my site. this is why I
need a script to pass the value.
In my menu I use the following code to send the sub-menu options.
Sub-menu option 1: ( code below )
MainIframepage.asp?ifp=Template_Code_Files/file1_for_iframes.htm
and ? where is the problem ? it is basic html ...
<form action="MainIframepage.asp" target="Iframe001" method="get">
<select name="ifp">
<option selected="selected"
value="Template_Code_Files/default_menu.htm">Main Menu</option>
<option
value="Template_Code_Files/file1_for_iframe.htm">sub-menu 1</option>
<option
value="Template_Code_Files/file2_for_iframe.htm">sub-menu 2</option>
</select>
<input type="submit" value="GO">
</form>
Now for the MainIframepage.asp file I created the following Iframe like
this---and it works fine.
<iframe src="<%=Request.QueryString("ifp")%>" name="Iframe001"
width="750px" height="920px" scrolling="yes" id="Iframe001">If you are
reading this then your browser cannot view Iframe, Please upgrade you
browser.
Sorry I am not to your orders !
If you want I pay a visit to your site
please give me a page I can read !
That't to say insert betwen tags of iframe a link to the plan of site with
links in basic html sending in self window.
Your way of doing is a real expression of incorrection and unpoliteness
</iframe>
Now the problem is for me is what happens if someone enters the page
without clicking an sub-option. ( Like for instance, coming from a
bookmark OR if the session times out.) he will get an empty Iframe.
Do not understand :
- the link is on the page (even in an option of select)
- the mechanism of send is in the browser
If there is a question of time spent on site it is the job of your asp :
time out or time unexisting ? hop ! go to page default
and ... I know anything about asp.
your [Request.QueryString("ifp")] has to enquiry if 'ifp' exists
if not : hop -> default page
if it is : hop ! what is write in url (remenber : target="Iframe001")
as I know anything in asp
I would have given the default page to the src of iframe
<iframe src="default.htm" name="Iframe001" width="750px" blah>
Activing menu will send a page to the iframe with variable ifp to obey
The querry about ifp and its different answeres would have to be in your
"MainIframepage.asp"
Is there not a ng for asp ?
--
Stephane Moriaux et son [moins] vieux Mac