The following code worked perfectly when I was using a normal window, but now that I have changed it to a frameset, it does not work. I have been reading as much as I can find on the subject and I realize that there are a different set of rules with "parent" etc. Please advise.

<SCRIPT language="JavaScript">
	<!--
	// reset timer
	var timer = window.setTimeout('closeWindow()',1800000);
	
	function resetTimer()
	{
	window.opener.resetTimer();
	window.clearTimeout(timer);
	timer = window.setTimeout('closeWindow()',1800000);
	}
	
	function closeWindow()
	{
	window.close();
	}
	//-->
</SCRIPT>

<BODY onFocus="resetTimer()">

Use top.your_frame_name or window.frames to get the frame reference.(here top is the global window object).

Read this for more information about DOM.

Here is my problem and it may be that you are talking over my head. I want to close the frameset window. It is not a frame.

> I want to close the frameset window. It is not a frame.
Do you know what you are saying? Frames are defined in the frameset tag and without frame tags, frameset is of no use. So how is that "its not a frame"?

Paste the working example and maybe then it would be easier for us to render help.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.