Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    pml
    pml is offline
    New Coder
    Join Date
    Mar 2005
    Posts
    31
    Thanks
    0
    Thanked 0 Times in 0 Posts

    How to pass arguments to a frame without that frame aquiring the "top" position?

    Why does the URLs refuse to display retrieved value in upper frame in a framset?
    I have a static URL with two links. They both pass an argument to an ASP page that retrieves the value and should display the value of the querystring in the upper frame. The problem is that it is not the frameset and the two frames that are displayed when either of the two links are clicked (with the passed argument displayed in the upper frame). Instead the ASP-page that retrieves the value from the querystring completely covers the screen. That’s not what I want. How can I display a frameset and at the same time pass an argument to one of the frames without the receiving frame acquiring the “top”-position? Anyone who has a good suggestion on how to achieve that?

    This is static.htm
    <a href="TestFrame1.asp?show=yes" target="main">Send yes</a> <br>
    <a href="TestFrame1.asp?show=no" target="main">Send no</a>

    This is frameset.asp
    <frameset rows="*,80" frameborder="yes" border="1" framespacing="0">
    <frame src="TestFrame1.asp" name="main">
    <frame src="TestFrame2.asp" name="bottom" scrolling="NO" noresize>
    </frameset>

    TestFrame1.asp
    <%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>
    <%
    MyVariable = request.QueryString("show")
    %>
    <html>
    <body bgcolor="#996633">
    You clicked: <%=MyVariable%>
    </body>
    </html>

    TestFrame2.asp
    <%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>
    <html>
    <body>
    </body>
    </html>

  • #2
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    11,048
    Thanks
    0
    Thanked 251 Times in 247 Posts
    This is probably what you want.

    static.htm
    <a href="frameset.asp?show=yes" target="main">Send yes</a> <br>
    <a href="frameset.asp?show=no" target="main">Send no</a>

    frameset.asp:
    <frameset rows="*,80" frameborder="yes" border="1" framespacing="0">
    <frame src="TestFrame1.asp?show=<%=request.QueryString("show")%>" name="main">
    <frame src="TestFrame2.asp" name="bottom" scrolling="NO" noresize>
    </frameset>


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •