Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Submit a Form in IFRAME

Status
Not open for further replies.

venur

MIS
Aug 26, 2003
418
US
Hi,

I have page with 2 Iframes. Iframe_1 has a html Form and Iframe_2 has a Preview of the page. When the html form in Iframe_1 is submited its loding the result page in Iframe_1. But I need the result need to be display it in a new page with submited form values.

Help is greatly appriceted.

Thanks
 
Hi,

Thank you for the quick response. "_blank" opens up a new window which I does't want to. I need to load the new page in the same window.

Below is the code. Try to submit the form in nf.html. I want the window to open in main.html with out iframes

main.html
Code:
<html>

<head>
<meta name="GENERATOR" content="Microsoft FrontPage 5.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>New Page 1</title>
</head>
<style>
     .odd{background-color: white;}
     .even{background-color: yellow ;}
</style>
<body>

<p><iframe name="frame_form" width="937" height="439" src="nf.html">
Your browser does not support inline frames or is currently configured not to display inline frames.</iframe></p>
<p><iframe name="frame_preview" width="939" height="321" src="np.html">
Your browser does not support inline frames or is currently configured not to display inline frames.</iframe></p>

</body>

</html>

Code:
<html>

<head>
<meta name="GENERATOR" content="Microsoft FrontPage 5.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>New Page 1</title>
<style>
<!--
div.Section1
	{page:Section1;}
p
	{margin-right:0in;
	margin-left:0in;
	font-size:12.0pt;
	font-family:"Times New Roman";
	}
 p.MsoNormal
	{mso-style-parent:"";
	margin-bottom:.0001pt;
	font-size:12.0pt;
	font-family:"Times New Roman";
	margin-left:0in; margin-right:0in; margin-top:0in}
-->
</style>
<style>
     .odd{background-color: white;}
     .even{background-color: yellow ;}
</style>
</head>

<body>
<p class="MsoNormal" style="TEXT-ALIGN: center" align="center">
<span style="COLOR: blue; FONT-FAMILY: Arial">[VIA FACSIMILE, CERTIFIED OR 
OVERNIGHT MAIL]</span></p>


</body>

</html>

Code:
<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
    <title>Form</title>
  </head>
  
  <body>
  <form name="form1" action="np.html"  target="_blank">
  <table class="xu" cellpadding="0" cellspacing="0" border="0" width="100%" summary="">
   <tr> 
     <td>&nbsp;</td>
     <td width="100%">Form</td>
     <td>&nbsp;</td>
   </tr>
   <tr> 
   <td></td>
   <td class="xq"> 
    <table cellpadding="0" cellspacing="0" border="0" width="921" summary="" height="280">
     
     <tr> 
      <td align="left" valign="middle" height="22" width="203">
          <span class="x8">Name</span>
      </td>
      <td width="24" valign="middle" height="22">&nbsp;</td>
      <td width="519" valign="middle" height="22"><input type="text"  size="20" name="name"  value=""  title="Enter Name" onFocus="parent._over('name')" onBlur="parent._out('name')"></td>
      <td align="right" valign="middle" height="22" width="175">&nbsp;</td>
     </tr>
     
     
     
    </table>
    <table width="100%" cellpadding="0" cellspacing="0" border="0" summary="">
     <tr> 
       <td width="100%"> 
        <input type="submit" value="submit">
       </td>
      </tr>
    </table>
    </td>
      <td>&nbsp;</td>
    </tr>
   </table>
</form>
  </body>
</html>

Thanks
 

You might want to try "_parent", as if you ever move your site into a frameset, you might find that "_top" breaks out of it.

Hope this helps,
Dan


[tt]D'ya think I got where I am today because I dress like Peter Pan here?[/tt]
[banghead]

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top