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
    New to the CF scene
    Join Date
    Jan 2004
    Location
    Auburn, AL
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    javascript frameset events

    Hello all. I'm new to the board and hope to get help as well as provide help for others. I am trying to time out a user after 20 mins of inacitivity. To do this I am using some timeout functions in javascript. The problem is I want to be able to monitor inactivity in a frameset. I tried to use onClick and onKeyPress, but this will not work in a frameset. I know there is a way to do this, but I'm new to javascript. Any help would be appreciated.

    <html>
    <head>
    <title>title</title>
    </head>
    <frameset rows="60,*" border="0" onload="framenumber()";>
    <frame src="C:/rsspMenu.jsp" name="topFrame" marginwidth="0" marginheight="0" scrolling="Auto" frameborder="No" noresize framespacing="0">
    <frame src="rsspHome.htm" name="bottomFrame" marginwidth="5" marginheight="20" scrolling="Auto" noresize>
    </frameset>
    </html>

  • #2
    New to the CF scene
    Join Date
    Jan 2004
    Location
    Auburn, AL
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    FYI

    Code:
    function initEventHandling () {
      for (var f = 0; f < frames.length; f++)
        frame[f].document.attachEvent('onkeypress', ieFrameChecker);
    }
    function ieFrameChecker () {
      try{
         alert("hello");
    	 }
      catch(e){document.write(error);}
    attachEvent is a microsoft function
    windows.captureEvents(Event.EventType) works for netscape I believe.


  •  

    Posting Permissions

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