Popup Receives Form Data

[Total: 0    Average: 0/5]

This will take the data in the form and place it on the new popup window.

Head Code:

<script language = "JavaScript"> 
function create(_f) { 
  storywin = window.open(); 
  with (storywin.document)
      writeln ("<h2>Items One:</h2><BR> " + _f.sec1.value + "<br><br>"); 
      writeln ("<h2>Items Two:</h2><BR> " + _f.sec2.value + "<br><br>"); 
// --> 

Body Code:

<h1>Two Lists</h1> 
  <h2>Section One: </h2> 
  <BR><textarea name="sec1" cols="75" rows="10"></textarea> 
  <h2>Section Two:</h2> 
  <BR><textarea name="sec2" cols="75" rows="5"></textarea> 
  <BR><input type = "button" value="Generate Popup" onClick = "create(this.form)" name="button"> 
  <BR><input type="reset" name="Reset" value="Clear Form"> 

Times Viewed: 3

Leave a Reply

Your email address will not be published. Required fields are marked *