Loading ...
Sorry, an error occurred while loading the content.

Re: [NH] Re:Form submission from AOL

Expand Messages
  • Grant
    ... Hi Gary Hope this helps. Below works as a simplified version of your document with a script added to the document head If you think this does the trick
    Message 1 of 1 , Jun 4, 2000
    • 0 Attachment
      > this is very interesting, would you have or know where I could see
      > source code for what you describe below?
      >
      > Gary

      Hi Gary Hope this helps.
      Below works as a simplified version of your document with a script added to
      the document head
      If you think this does the trick copy the script to the head of your
      document then make sure the last form element is the input button.
      <input type="button" value="Submit" onclick="assemble()" />
      This last input element is excluded from the end loop count set by the max
      variable
      var max = document.forms[0].length - 1
      I would do away with the reset button as useability guru Jakob Nielsen
      suggests
      http://www.useit.com/alertbox/20000416.html


      <html>
      <head>
      <title></title>
      <script>
      function assemble()
      {
      var msg = ""
      var max = document.forms[0].length - 1
      for (var i = 0;i < max; i++)
      {
      msg += document.forms[0].elements[i].name
      msg += " : = "
      msg += document.forms[0].elements[i].value;
      msg += "\n"
      }
      openWin(msg)
      }

      var win;

      function openWin(txt)
      {
      if (!win || win.closed)
      {
      var start = ''
      var body = ''
      var end = ''
      start += '<html> <head> <title>Submitter</title> </head> <body>'
      body += '<p>Thankyou for you submission,Please check your details then
      use the send email button below , if your email client is not setup to send
      email automatically please rightclick selected text then copy and paste text
      directly into your email client and send to gmoyers@...; </p>'
      body += '<form action="mailto:gmoyers@..." method="post"
      enctype="text/plain">'
      body += '<textarea name="submiter" rows="6" cols="40" readonly>'
      body += txt
      body += '</textarea><br><input type="submit" name="submit" value="send
      email now"></form>'
      end += '</body> </html>'
      win = window.open('','submiter','scrollbars,width=400,height=500')
      win.document.write(start , body , end)
      win.focus()
      win.document.forms[0].submiter.select()
      }
      else
      {
      win.document.forms[0].submiter.value = txt
      win.focus();
      win.document.forms[0].submiter.select()
      }
      }
      </script>

      </head>
      <body>
      <form action="mailto:gmoyers@..." method="post" enctype="text/plain">
      <p><strong>Husband's Name</strong> <input type="Text" name="Husband"
      maxlength="65" size="65" /></p>

      <p>Birthday <input type="Text" name="birthday" maxlength="13" size="13"
      /></p>

      <p>Location <input type="Text" name="location" maxlength="38" size="38"
      /></p>

      <p>Source <input type="Text" name="source" maxlength="41" size="41" /></p>

      <p><input type="button" value="Submit" onclick="assemble()"/></p>
      </form>
      </body>
      </html>
    Your message has been successfully submitted and would be delivered to recipients shortly.