SarahKate31
Programmer
hi everyone -
i saw a post similar to this one, but it didn't really answer my question, so i posted this one...
i have a frameset with 3 frames (one hidden)...summary.htm is initially loaded into the "main" frame. this page has links that will let you view different reports. when you click on the link, I would like to load that report using submit() into the "rpt" frame and NOT into the "main" frame. i have the following function that is attached to the onClick event for the links and right now it is loading the report into both frames. I need to leave the existing page in "main" and only load the report in "rpt"...
index.htm-->
<frameset rows="0%,50%,50%" border="0" frameSpacing="0" frameBorder="0" id="LKQFrames">
<frame name="data" src="data.htm" scrolling="no" noresize>
<frame name="main" src="summary.htm" scrolling="no">
<frame name="rpt" src="report.htm" scrolling="no">
</frameset>
summary.htm -->
<html>
<head>
<script language="javascript">
function RunReport(rptName) {
window.parent.data.Name=document.SumForm.txtName.value
window.parent.data.Date=document.SumForm.txtDate.value
window.parent.data.Age=document.SumForm.txtAge.value
if(rptName=="Report1") page="Report1.htm"
if(rptName=="Report2") page="Report2.htm"
if(rptName=="Report3") page="Report3.htm"
window.parent.rpt.src=page
document.SumForm.action=page
document.SumForm.submit()
}
</script>
</head>
<body>
<form action="" method=post id=SumForm name=SumForm>
<table>
<tr>
<td><input type=text id=txtName></td>
<td><input type=text id=txtDate></td>
<td><input type=text id=txtAge></td>
</tr>
<tr>
<td><A href="javascriptnclick=RunReport('Report1')>Report 1</A></TD>
<td><A href="javascriptnclick=RunReport('Report2')>Report 2</A></TD>
<td><A href="javascriptnclick=RunReport('Report3')>Report 3</A></TD>
</tr>
</table>
</form>
</body>
</html>
if anyone can help out, i'd really appriciate it!
thanks, kate
i saw a post similar to this one, but it didn't really answer my question, so i posted this one...
i have a frameset with 3 frames (one hidden)...summary.htm is initially loaded into the "main" frame. this page has links that will let you view different reports. when you click on the link, I would like to load that report using submit() into the "rpt" frame and NOT into the "main" frame. i have the following function that is attached to the onClick event for the links and right now it is loading the report into both frames. I need to leave the existing page in "main" and only load the report in "rpt"...
index.htm-->
<frameset rows="0%,50%,50%" border="0" frameSpacing="0" frameBorder="0" id="LKQFrames">
<frame name="data" src="data.htm" scrolling="no" noresize>
<frame name="main" src="summary.htm" scrolling="no">
<frame name="rpt" src="report.htm" scrolling="no">
</frameset>
summary.htm -->
<html>
<head>
<script language="javascript">
function RunReport(rptName) {
window.parent.data.Name=document.SumForm.txtName.value
window.parent.data.Date=document.SumForm.txtDate.value
window.parent.data.Age=document.SumForm.txtAge.value
if(rptName=="Report1") page="Report1.htm"
if(rptName=="Report2") page="Report2.htm"
if(rptName=="Report3") page="Report3.htm"
window.parent.rpt.src=page
document.SumForm.action=page
document.SumForm.submit()
}
</script>
</head>
<body>
<form action="" method=post id=SumForm name=SumForm>
<table>
<tr>
<td><input type=text id=txtName></td>
<td><input type=text id=txtDate></td>
<td><input type=text id=txtAge></td>
</tr>
<tr>
<td><A href="javascriptnclick=RunReport('Report1')>Report 1</A></TD>
<td><A href="javascriptnclick=RunReport('Report2')>Report 2</A></TD>
<td><A href="javascriptnclick=RunReport('Report3')>Report 3</A></TD>
</tr>
</table>
</form>
</body>
</html>
if anyone can help out, i'd really appriciate it!
thanks, kate