USING IIS 5.1, and Windows XP pro, the following form works on my system,
and I can use as many form elements as I wish, as long as all form elements
have the same name: "words", in this example.
Help -- why can`t I give each form element a different name? Any
suggestions will be gratefully appreciated.
Also,See example at very bottom of something that once worked on a remote
server, but doesn't on IIS 5.1, windows xp pro
<%@LANGUAGE="VB SCRIPT"%>
<%
Dim MyMail
Set MyMail = Server.CreateOb ject("CDO.Messa ge")
MyMail.TextBody = Request.Form("w ords")
MyMail.From = "postmaster@loc alhost"
MyMail.To = "postmaster@loc alhost"
MyMail.Subject = "CDOSYS for Windows 2000/XP"
MyMail.Send()
Set MyMail = Nothing
%>
<HTML>
<FORM NAME="TextBody" METHOD="post" ACTION="gusto44 444444.asp">
<P><BR>
<input type="text" NAME= "words" ID="words" COLS="28" ROWS="1">
Name <br>
<input type="text" NAME= "words" ID="words" COLS="28" ROWS="1">
<SPAN CLASS="book_ant igua">E-Mail</SPAN><BR CLEAR="all">
<input type="text" name= "words" id="words" cols="28" rows="1">
Phone</P>
<BR>
<TEXTAREA NAME = "words" ID="words" COLS="18" ROWS="2"
wrap="VIRTUAL"> </TEXTAREA>
<SPAN CLASS="book_ant igua">Write Here </SPAN><BR CLEAR="all">
<P>
<INPUT TYPE="submit" NAME="Submit" VALUE="Submit, e-mail required"
ALIGN="DEFAULT" >
<input type="reset" name="Reset" value="Reset">
</P>
<P>
</P>
<P>
</P>
</FORM>
<%
dim words
words=Request.F orm("words")
If words<>"" Then
Response.Write( "Thanks " & words & "!<br />")
Response.Write( "We'll respond soon")
End If
%>
EXAMPLE AT BOTTOM -- WORKED IN PAST
BUT NOT NOW
Dim myMail
Set myMail = Server.CreateOb ject("CDONTS.Ne wMail")
Request.Form("e mail1")
Request.Form("n ame")
Request.Form("p hone")
Request.Form("w ords") 4 4850
You can name your form fields whatever you want, and then access them by
Request.Form("n ameOfInput")
MyMail.TextBody = Request.Form("i nput1") & vbCrLf & Request.Form("i nput2")
Ray at work
"whyyyy" <wh****@discuss ions.microsoft. com> wrote in message
news:10******** *************** ***********@mic rosoft.com... USING IIS 5.1, and Windows XP pro, the following form works on my system, and I can use as many form elements as I wish, as long as all form elements have the same name: "words", in this example.
Help -- why can`t I give each form element a different name? Any suggestions will be gratefully appreciated.
Also,See example at very bottom of something that once worked on a remote server, but doesn't on IIS 5.1, windows xp pro <%@LANGUAGE="VB SCRIPT"%> <% Dim MyMail Set MyMail = Server.CreateOb ject("CDO.Messa ge") MyMail.TextBody = Request.Form("w ords") MyMail.From = "postmaster@loc alhost" MyMail.To = "postmaster@loc alhost" MyMail.Subject = "CDOSYS for Windows 2000/XP" MyMail.Send() Set MyMail = Nothing %>
You're directly assigning the entire message body, the values of
request.form("w ords")
Why don't you do something like:
MessageBody = Request.Form("e mail1") & vbCrLf & _
Request.Form("n ame") & vbCrLf & _
Request.Form("p hone") & vbCrLf & _
Request.Form("w ords")
....
MyMail.TextBody = MessageBody
The example you have at the bottom could never have worked. All you do is
create the object and then type out Request.Form(". ..")... this should yield
a type mismatch error or something.
"whyyyy" <wh****@discuss ions.microsoft. com> wrote in message
news:10******** *************** ***********@mic rosoft.com... USING IIS 5.1, and Windows XP pro, the following form works on my system, and I can use as many form elements as I wish, as long as all form elements have the same name: "words", in this example.
Help -- why can`t I give each form element a different name? Any suggestions will be gratefully appreciated.
Also,See example at very bottom of something that once worked on a remote server, but doesn't on IIS 5.1, windows xp pro <%@LANGUAGE="VB SCRIPT"%> <% Dim MyMail Set MyMail = Server.CreateOb ject("CDO.Messa ge") MyMail.TextBody = Request.Form("w ords") MyMail.From = "postmaster@loc alhost" MyMail.To = "postmaster@loc alhost" MyMail.Subject = "CDOSYS for Windows 2000/XP" MyMail.Send() Set MyMail = Nothing %>
<HTML>
<FORM NAME="TextBody" METHOD="post" ACTION="gusto44 444444.asp"> <P><BR> <input type="text" NAME= "words" ID="words" COLS="28" ROWS="1"> Name <br> <input type="text" NAME= "words" ID="words" COLS="28" ROWS="1"> <SPAN CLASS="book_ant igua">E-Mail</SPAN><BR CLEAR="all"> <input type="text" name= "words" id="words" cols="28" rows="1"> Phone</P> <BR>
<TEXTAREA NAME = "words" ID="words" COLS="18" ROWS="2" wrap="VIRTUAL"> </TEXTAREA> <SPAN CLASS="book_ant igua">Write Here </SPAN><BR CLEAR="all"> <P> <INPUT TYPE="submit" NAME="Submit" VALUE="Submit, e-mail required" ALIGN="DEFAULT" > <input type="reset" name="Reset" value="Reset"> </P> <P> </P> <P>
</P> </FORM> <% dim words words=Request.F orm("words") If words<>"" Then Response.Write( "Thanks " & words & "!<br />") Response.Write( "We'll respond soon") End If %>
EXAMPLE AT BOTTOM -- WORKED IN PAST
BUT NOT NOW
Dim myMail Set myMail = Server.CreateOb ject("CDONTS.Ne wMail")
Request.Form("e mail1") Request.Form("n ame") Request.Form("p hone") Request.Form("w ords")
Many thanks, Ray
I`ll let you know how it works
& vbCrLf something new for me, as is just about everything
AL
"Ray Costanzo [MVP]" wrote: You can name your form fields whatever you want, and then access them by Request.Form("n ameOfInput")
MyMail.TextBody = Request.Form("i nput1") & vbCrLf & Request.Form("i nput2")
Ray at work
"whyyyy" <wh****@discuss ions.microsoft. com> wrote in message news:10******** *************** ***********@mic rosoft.com... USING IIS 5.1, and Windows XP pro, the following form works on my system, and I can use as many form elements as I wish, as long as all form elements have the same name: "words", in this example.
Help -- why can`t I give each form element a different name? Any suggestions will be gratefully appreciated.
Also,See example at very bottom of something that once worked on a remote server, but doesn't on IIS 5.1, windows xp pro <%@LANGUAGE="VB SCRIPT"%> <% Dim MyMail Set MyMail = Server.CreateOb ject("CDO.Messa ge") MyMail.TextBody = Request.Form("w ords") MyMail.From = "postmaster@loc alhost" MyMail.To = "postmaster@loc alhost" MyMail.Subject = "CDOSYS for Windows 2000/XP" MyMail.Send() Set MyMail = Nothing %>
and thanks Aaron
"Aaron Bertrand [SQL Server MVP]" wrote: You're directly assigning the entire message body, the values of request.form("w ords")
Why don't you do something like:
MessageBody = Request.Form("e mail1") & vbCrLf & _ Request.Form("n ame") & vbCrLf & _ Request.Form("p hone") & vbCrLf & _ Request.Form("w ords")
....
MyMail.TextBody = MessageBody The example you have at the bottom could never have worked. All you do is create the object and then type out Request.Form(". ..")... this should yield a type mismatch error or something.
"whyyyy" <wh****@discuss ions.microsoft. com> wrote in message news:10******** *************** ***********@mic rosoft.com... USING IIS 5.1, and Windows XP pro, the following form works on my system, and I can use as many form elements as I wish, as long as all form elements have the same name: "words", in this example.
Help -- why can`t I give each form element a different name? Any suggestions will be gratefully appreciated.
Also,See example at very bottom of something that once worked on a remote server, but doesn't on IIS 5.1, windows xp pro <%@LANGUAGE="VB SCRIPT"%> <% Dim MyMail Set MyMail = Server.CreateOb ject("CDO.Messa ge") MyMail.TextBody = Request.Form("w ords") MyMail.From = "postmaster@loc alhost" MyMail.To = "postmaster@loc alhost" MyMail.Subject = "CDOSYS for Windows 2000/XP" MyMail.Send() Set MyMail = Nothing %>
<HTML>
<FORM NAME="TextBody" METHOD="post" ACTION="gusto44 444444.asp"> <P><BR> <input type="text" NAME= "words" ID="words" COLS="28" ROWS="1"> Name <br> <input type="text" NAME= "words" ID="words" COLS="28" ROWS="1"> <SPAN CLASS="book_ant igua">E-Mail</SPAN><BR CLEAR="all"> <input type="text" name= "words" id="words" cols="28" rows="1"> Phone</P> <BR>
<TEXTAREA NAME = "words" ID="words" COLS="18" ROWS="2" wrap="VIRTUAL"> </TEXTAREA> <SPAN CLASS="book_ant igua">Write Here </SPAN><BR CLEAR="all"> <P> <INPUT TYPE="submit" NAME="Submit" VALUE="Submit, e-mail required" ALIGN="DEFAULT" > <input type="reset" name="Reset" value="Reset"> </P> <P> </P> <P>
</P> </FORM> <% dim words words=Request.F orm("words") If words<>"" Then Response.Write( "Thanks " & words & "!<br />") Response.Write( "We'll respond soon") End If %>
EXAMPLE AT BOTTOM -- WORKED IN PAST
BUT NOT NOW
Dim myMail Set myMail = Server.CreateOb ject("CDONTS.Ne wMail")
Request.Form("e mail1") Request.Form("n ame") Request.Form("p hone") Request.Form("w ords") This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: ThisIsMe |
last post by:
I am using this php email form and it seems to work. But I would like
for
the option for attn$ Webmaster to go to a different email address than
the
mymail$
Please be Kind to us newbies...
can someone modify this and resend it so I can have the form send to 2
different email addresses? Or maybe three if that is possible determined
by what attn$ option is used.
|
by: Christopher Brandsdal |
last post by:
Hi!
I get an error when I run my code
Is there any other way to get te information from my form?
Heres the error I get and the code beneath.
Line 120 is market with ''''''''''''Line 120'''''''''''''''''''''
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
|
by: Wayne Wengert |
last post by:
I am trying to use Request.Form to differentiate between when a page
containing a form is first loaded and when it is reloaded as a result of the
user clicking on the Submit button. Things are not working as expected. Some
snippets of my code are:
fSubmit = Request.Form("Submit1") = "Process"
Response.Write("Submit1 " & Request.Form("Submit1") & "<br>")
Response.Write("fSubmit: " & fSubmit & "<br>")
......
|
by: Matt |
last post by:
My problem is when the user click the submit button, it will launch another
new window for the request page. I want to confirm we cannot use JavaScript
open window functions to open a request page? The following page2.asp won't
output the value entered in page1.asp. However, if we do <form
action="page2.asp" method="get" target="_blank">, then it will open a new
window for the request page, instead of using the same window as page1.asp....
|
by: Paxton |
last post by:
At the risk of being told "If it ain't broke, don't fix it", my code works,
but is ugly.
Part of the admin site I'm working on at the moment includes a facility for
users to enter Formulations (recipes for making cosmetics etc) in 3 stages:
Stage 1: basic info such as title, method etc and number of Phases (steps in
recipe).
Stage 2: dynamically generated form containing the exact number of phases as
textboxes, depending on the number...
| |
by: Jack |
last post by:
Hi,
I am trying to get a thorough understanding of a code where a addition or
deletion of records can be done from a list of records. For addition part of
the form, data is being obtained from set of input boxes.
The following is the code being used:
If Len(Request.Form("ID_0"))>0 Then
AuthorID=Request.Form("ID_0")
FName=Request.Form("fName_0")
LName=Request.Form("lName_0")
|
by: eric.goforth |
last post by:
Hello,
I'm working with a classic asp page that calls another classic asp
page. The html in my calling page looks like:
<form method="post"
action="/includes/mypage2.asp?subtype=MyType&ecd=1&eid=97702">
....Do some stuff
|
by: Michael Kujawa |
last post by:
I am using the following to create an SQL statement
using the names and values from request.form.
The loop goes through each item in request.form
The issue comes in having an additional "and" at the end
of the loop and the value of x3 as not all options may be selected
from the form yet the loop goes through the entire request.form list
I have to add addtional code to strip off the last "and"
and was wondering if there is a way to...
|
by: buntyindia |
last post by:
Hi,
I have a very strange problem with my application.
I have developed it using Struts.
I have a TextBox With Some fixed value in it and on Submit iam passing it to another page.
<html:form action="/login">
<html:text property="userName" value="Bunty"/>
<html:submit/>
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
| |
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |