Please can someone help me with this.
The first frame i called 'side' and contains a little menu
The second frame is the content of the choosen menu-item.
I want to know if a user pressed the 'add record' button from the menu (side-frame) or the 'save to database' button from the content-frame
Here is the code:
index.htm (frameset)
<html>
<head>
<title>framespage</title>
</head>
<frameset rows="100%" frameborder="0" border="0" framespacing="0">
<frameset cols="175,86%">
<frame src="side.asp" name="side" id="side" title="side" scrolling="no" noresize / marginwidth="0" marginheight="0" target="_side">
<frame name="content" src="content.asp" marginwidth="0" marginheight="0" scrolling="auto" target="_self">
</frameset>
<noframes>
<body topmargin="0" leftmargin="0">
</body>
</noframes>
</frameset>
</html>
side.asp
<html>
<head>
</head>
<script type="text/javascript">
function Goto(Page)
{
parent.content.document.location.href = Page;
}
</script>
<body bgcolor="#008000">
<p><input type="button" value="Home" name="cmd_home" onclick=""></p>
<p><input type="button" value="add record" name="cmd_add" onclick="Goto('record_add.asp?new=1')"></p>
<p><input type="button" value="Login" name="cmd_login" onclick=""></p>
<p> </p>
<p> </p>
<p><b><font color="#FFFFFF">this is the side frame</font></b></p>
</html>
content.asp
<html>
<head>
<title>content</title>
<base target="_self">
</head>
<body bgcolor="#800000">
<p><b><font color="#FFFFFF">this is the content frame</font></b></p>
</html>
record_add.asp
<html>
<body bgcolor="#800000">
<form method="POST">
<p><input type="text" name="txt_text1" size="20"></p>
<p><input type="submit" value="Save to database" name="cmd_save"></p>
</form>
<p><b><font color="#FFFFFF">this is the content frame</font></b></p>
</html>
The first frame i called 'side' and contains a little menu
The second frame is the content of the choosen menu-item.
I want to know if a user pressed the 'add record' button from the menu (side-frame) or the 'save to database' button from the content-frame
Here is the code:
index.htm (frameset)
<html>
<head>
<title>framespage</title>
</head>
<frameset rows="100%" frameborder="0" border="0" framespacing="0">
<frameset cols="175,86%">
<frame src="side.asp" name="side" id="side" title="side" scrolling="no" noresize / marginwidth="0" marginheight="0" target="_side">
<frame name="content" src="content.asp" marginwidth="0" marginheight="0" scrolling="auto" target="_self">
</frameset>
<noframes>
<body topmargin="0" leftmargin="0">
</body>
</noframes>
</frameset>
</html>
side.asp
<html>
<head>
</head>
<script type="text/javascript">
function Goto(Page)
{
parent.content.document.location.href = Page;
}
</script>
<body bgcolor="#008000">
<p><input type="button" value="Home" name="cmd_home" onclick=""></p>
<p><input type="button" value="add record" name="cmd_add" onclick="Goto('record_add.asp?new=1')"></p>
<p><input type="button" value="Login" name="cmd_login" onclick=""></p>
<p> </p>
<p> </p>
<p><b><font color="#FFFFFF">this is the side frame</font></b></p>
</html>
content.asp
<html>
<head>
<title>content</title>
<base target="_self">
</head>
<body bgcolor="#800000">
<p><b><font color="#FFFFFF">this is the content frame</font></b></p>
</html>
record_add.asp
<html>
<body bgcolor="#800000">
<form method="POST">
<p><input type="text" name="txt_text1" size="20"></p>
<p><input type="submit" value="Save to database" name="cmd_save"></p>
</form>
<p><b><font color="#FFFFFF">this is the content frame</font></b></p>
</html>