Hello
I have the following code in a contact form field in my aspx file:
In my aspx.vb file, I have:
When I look at the contact form through a browser, I see this:
[imgnothumb]https://bytes.com/attachment.php? attachmentid=92 99d1511976180[/imgnothumb]
My understanding with that error is that it is looking for a valid email address and it is not possible to do that because the Webmaster, who is creating this SMTP form, cannot possibly know the user's email address before he types it in.
user_email is not the variable, it is the name of the email field. Should it be the variable useremail? When I try that with the quotation marks it gives that same 'not in the form required for an email address error', and when I try it without the quotation marks, I get: Value cannot be null. Parameter name: address
Thanks for any advice.
I have the following code in a contact form field in my aspx file:
Code:
<input type="email" name="user_email" class="form-control" placeholder="Email Address" required="required">
Code:
Dim Email As String = "useremail"
'Request.Form - extract data from form fields
Dim useremail As String = Request.Form("user_email")
'create the mail message
myMessage.From = New MailAddress("user_email") 'User email completed by user
[imgnothumb]https://bytes.com/attachment.php? attachmentid=92 99d1511976180[/imgnothumb]
My understanding with that error is that it is looking for a valid email address and it is not possible to do that because the Webmaster, who is creating this SMTP form, cannot possibly know the user's email address before he types it in.
user_email is not the variable, it is the name of the email field. Should it be the variable useremail? When I try that with the quotation marks it gives that same 'not in the form required for an email address error', and when I try it without the quotation marks, I get: Value cannot be null. Parameter name: address
Thanks for any advice.
Comment