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 5 of 5
  1. #1
    Regular Coder
    Join Date
    Jan 2003
    Location
    West Virginia
    Posts
    110
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Moving frameset to right onload

    I need an information page popup to load on the right side of the screen when the user clicks a hyperlink (requesting the info). This popup page is in frames, and I'm having trouble getting it to work.

    With a regular html page I'd just put onLoad="moveTo(20,200);" in the <body> tag, but with a frameset I have no body tag so am not sure how to proceed. I tried this without success:
    Code:
    <head>
    <SCRIPT LANGUAGE="JavaScript">
    <!-- Begin
    function win() {
    onLoad="moveTo(20,200);"
    }
    // End -->
    </script>
    </head>
    Is there a way to move the small frameset window to the right (onload) using js?? Thanks...
    Reno CF

  • #2
    Senior Coder
    Join Date
    Aug 2002
    Location
    Kansas City, Kansas
    Posts
    1,518
    Thanks
    0
    Thanked 2 Times in 2 Posts
    Can we see the code from the page you are talking about?

  • #3
    Regular Coder
    Join Date
    Jan 2003
    Location
    West Virginia
    Posts
    110
    Thanks
    0
    Thanked 0 Times in 0 Posts
    The actual popup would be launched from a regular html page using this snippet:

    Code:
    <A href="alumni.html" target="popup" onclick="window.open('alumni.html', 'popup', 'width=300,height=450,scrollbars=1,resizable=1'); return false"><b>View alumni pictures</b></a>
    And this is the code for the frameset that I'd like to have load on the right side of the screen (I had tried putting the js referenced in my first post in the <head> of this doc...

    Code:
    <html>
    <head>
    <title>Reunion Pictures</title>
    </head>
    
    <frameset rows="44,*" framespacing="0" frameborder="1" bordercolor="#C0C0C0" border="0">
    
    <frame src="alumni_nav.html" frame name="F1" frameborder="1" scrolling="no" noresize  target="F2">
    
    <frame src="alumni_message.html" frameborder="1" framespacing="0" frame name="F2">
    
    
    <noframes>
    <body bgcolor="#FFFFFF">
      <p>This page uses frames, but your browser doesn't support them. If you have gotten this message then you possibly need to upgrade your current browser.</p>
    </body></noframes>
    
    </frameset>
    </html>
    Reno CF

  • #4
    Senior Coder
    Join Date
    Jun 2002
    Location
    Wichita
    Posts
    3,880
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Are you unaware that you can position the window this way:

    Code:
    window.open('alumni.html', 'popup', 'top=20,screenX=20,left=200,screenY=200,width=300,height=450,scrollbars=1,resizable=1')
    You have to specify the positions twice, once for Netscape and once for IE since they can't agree on what to accept for positions but this way your window is opened in the right place and doesn't have to move.
    Check out the Forum Search. It's the short path to getting great results from this forum.

  • #5
    Regular Coder
    Join Date
    Jan 2003
    Location
    West Virginia
    Posts
    110
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thanks Roy -- that was exactly what I was hoping to find... works perfectly...
    Reno CF


  •  

    Posting Permissions

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