?
Solved

Dreamweaver MX Submit To E-mail Button

Posted on 2005-03-17
14
Medium Priority
?
195 Views
Last Modified: 2010-04-03
Hello all,

     I'm working on a site and am having an issue witht a Submit Button.  Basically the setup is that I have a text box and I want users to type in their e-mail address and then click the submit button.  I want that address to be seant to me via e-mail.  Now I know my host accepts cgi and perl but i'm clueless to that so i was setting it up where when they hit the submit button it would pop up Outlook with my e-mail address already in the TO field.  This works to a point but in the body it would put this:
Submit=Submit&textfield=test%40petv.com.  

Here is the html that I have:
<form name="form1" action="mailto:service@mydomain.com" method="post" >
 <input type="submit" name="Submit" value="Submit">
 <input type="reset" name="reset" value="Reset">
 <input type="text" name="textfield">

First Question is.  How do i get the body to be clear or at least have their e-mail address they typed in?  Second, how easy is it to setup using CGI where the e-mail is just sent to me without opeining their Mail Client?  Thanks for any help
0
Comment
Question by:epvc
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 7
  • 7
14 Comments
 
LVL 16

Expert Comment

by:vickerleung
ID: 13571119
epvc

Usually, we will simply use a hyperlink to send a email using Outlook

Say
<a href="mailto:service@mydomain.com">Contact Us</a>


If really want to send a email, as you say, have to use CGI, something like that
Please check the following tutorial, see if it suits you
http://www.mv.com/webtools/forms-info/form-submit-ex-em.html

Vicker
0
 

Author Comment

by:epvc
ID: 13588177
Is there a way from my HTML i am using to get the info they have typed into the form automatically put in the Body of the e-mail?
0
 
LVL 16

Expert Comment

by:vickerleung
ID: 13588389
epvc,

This line is copied from the link I posted above

    <p>
    Your comments?<br>
    <textarea name="comments" COLS=60 ROWS=8></textarea><br>

This is the part where the HTML pass the text to the email's body section

Vicker
0
On Demand Webinar: Networking for the Cloud Era

Ready to improve network connectivity? Watch this webinar to learn how SD-WANs and a one-click instant connect tool can boost provisions, deployment, and management of your cloud connection.

 

Author Comment

by:epvc
ID: 13588571
Ok I have that part...however when i test it I do have a text box which is great but when I click the SUBMIT Button the e-mail generates an e-mail and puts the right e-mail address which is great.  the problem is with the text in the text box.  It's not put in the body and this is what's put instead.

Submit=Submit&comments=test+message&textfield=  

What i entered in the text box is "Test Message"

How do i get rid of the stuff around it from coming up in the body?

0
 
LVL 16

Expert Comment

by:vickerleung
ID: 13589143
epvc,

can you use POST method instead of GET method?

Vicker
0
 

Author Comment

by:epvc
ID: 13598250
What's the difference between the two methods?
0
 
LVL 16

Expert Comment

by:vickerleung
ID: 13598299
epvc,

GET

the parameters will pass to the next page through URL
i.e. &comments=test+message&textfield=

POST

the parameters will pass to the next page through the HTTP header

Vicker
0
 

Author Comment

by:epvc
ID: 13598404
So as my current code is what should i change?

 <tr>
 <td width="185" height="46" valign="top">
 <form name="form1" action="mailto:service@activenettech.com" method="post" >
 <input type="submit" name="Submit" value="Submit">
 <input type="reset" name="reset" value="Reset">
 <input type="text" name="textfield">
 </form></td>
0
 
LVL 16

Expert Comment

by:vickerleung
ID: 13598419
epvc

Wait a minute

Do you mean that when you place something into the comment field and submit

You received a email with a body as follow?
Submit=Submit&comments=test+message&textfield=

Vicker
0
 

Author Comment

by:epvc
ID: 13598428
Yeah...so I have this text box with a submit button.

As a user i typed test message in the text box.  Then clicked the submit button.

I received the e-mail but in the body it has Submit=Submit&comments=test+message&textfield=.  I don't want that to be in the body when a user on the site clicks submit.
0
 
LVL 16

Accepted Solution

by:
vickerleung earned 1500 total points
ID: 13598435
epvc,

Okay let we try to modify to the following

 <tr>
 <td width="185" height="46" valign="top">
 <form name="form1" action="mailto:service@activenettech.com" method="post" >
 <input type="submit" value="Submit">
 <input type="reset" value="Reset">
 <input type="text" >
 </form></td>
0
 

Author Comment

by:epvc
ID: 13598524
Ok that gets rid of the Submit=Submit&comments=test+message&textfield= and give me a blank body.  Is there any easy way to get the data they put in the text box to automatically be used in the body of the e-mail?  This is better though...i'd rather it be blank then have the other stuff.
0
 
LVL 16

Expert Comment

by:vickerleung
ID: 13598715
epvc,

I need to check your cgi mail function before answering you this

Vicker
0
 

Author Comment

by:epvc
ID: 13615863
Ok....not sure how to do that.  Thanks though i think this will work for now.  
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

For those who don't know, Adobe Dreamweaver is a popular commercial web editor that enables you to design, build and manage complex websites. The editor is a WYSIWYG (What You See Is What You Get) web editor, which means that you can create your web…
This article is very specific and is only intended to help if you are installing Dreamweaver 8 in a Windows 7 environment with Office 2007 installed.   I'm not sure why Microsoft tends to release OS' that should not be released but they do.  Windows…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
How to fix incompatible JVM issue while installing Eclipse While installing Eclipse in windows, got one error like above and unable to proceed with the installation. This video describes how to successfully install Eclipse. How to solve incompa…
Suggested Courses

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question