
June 9th, 2005, 12:30 AM
|
 |
Contributing User
|
|
Join Date: Sep 2003
Posts: 61
Time spent in forums: 15 h 55 m 10 sec
Reputation Power: 10
|
|
Load Frames script
Hi all experts, I'm still fresh on javascript :
I got a code from the net. It's cool, but I'd like to modify it in the way that - the frame page won't be open in a new window, but of the same window where the link is from.
Thanks for help first.
Code:
<SCRIPT LANGUAGE="JavaScript">
<!-- This script and many more are available free online at -->
<!-- The JavaScript Source!! http://javascript.internet.com -->
<!-- Begin
function loadFrames(page1, page2) {
framecode = "<frameset cols='160,*' framespacing=0 frameborder='NO' border=0>"
+ "<frame src='" + page1 + "' scrolling='NO' noresize>"
+ "<frame name=frame_content src='" + page2 + "'>"
+ "</frameset>";
page = window.open("");
page.document.open();
page.document.write(framecode);
page.document.close();
}
// End -->
</script>
The link appeared as: <a href="javascript :loadFrames('menu.htm','quickstart.htm')">
__________________
Agnes
|