470,852 Members | 1,353 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,852 developers. It's quick & easy.

<input type="hidden" name="strInputElements" value="Name">

Forgive me if this seems like a stupid question but I need help...

I'm trying to do a simple online form that emails me the results from
a few fields.

Here is the code:
Expand|Select|Wrap|Line Numbers
  1. <form action="http://cm1web1/WebSurveyComponents/script/
  2. processform.asp" method="post">
  4. <!-- Mandatory "hidden" objects -->
  5. <p>
  6. <input type="hidden" name="strInputElements" readonly
  7. value="Suggestion">
  8. <input type="hidden" name="strInputElements" value="Name">
  9. <input type="hidden" name="strInputElements" value="Email">
  10. <input type="hidden" name="strInputElements" value="Business Unit">
  11. <input type="hidden" name="intSendMode" readonly value="0">
  12. <input type="hidden" name="strSendParms" readonly
  13. value="ma**@website.com,CSPS Intranet
  15. Suggestion Box">
  17. Name:
  18. <input type=text name="Name">
  19. <br>(optional, but required if you would like a response to your
  20. comments or suggestions)</p>
  21. <p>Email:
  22. <input type=text name="Email">
  23. <br>(optional)
  24. </p>
  25. <p>Business unit:
  26. <input type=text name="Business Unit">
  27. <br>(optional)
  28. </p>
  29. <p>
  30. <textarea name="Suggestion" rows="12" cols="40">Write your
  31. feedback or suggestion here</textarea>
  32. <br>
  33. <br>
  34. <input name="Send" type="submit" value="Send">
  35. &nbsp;&nbsp;&nbsp;
  36. <input name="Clear" type="reset" value="Clear">
  37. </p>
  38. <p>(Unless you fill in your name and/or email, this form is completely
  39. anonymous)</p>
  40. </form>
And the email I receive looks like this...

Field = Suggestion
Response = Write your feedback or suggestion here

Field = Name
Response =

Field = Email
Response =

Field = Business Unit
Response =

The "Suggestion" field works fine, but the Name, Email and Business
Unit fields all come through with blank responses.

Any ideas?

Jul 27 '07 #1
1 6679
All your fields are named strInputElements ? It looks like you confused the
name (that you'll use in request form) and the value of the field (that is
the value that Request.form will return). Try to use a different name for
each field and use this name in Request.form.

Note this is an ASP.NET group. It looks like you are rather working with ASP
in which case it's likely better to find another group for future posts...
Jul 27 '07 #2

This discussion thread is closed

Replies have been disabled for this discussion.

By using this site, you agree to our Privacy Policy and Terms of Use.