Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Community > MacNN Lounge > I suck at html help

I suck at html help
Thread Tools
Mac Elite
Join Date: Apr 2005
Location: Nashville, TN
Status: Offline
Reply With Quote
Jul 12, 2007, 09:59 PM
 
i am trying to create a simple form that emails info to me, and am having no luck. what am i doing wrong?

<form method="post" action="mailto:XXXX@yahoo.com">
<div align="left">
<font size="-1" face="Helvetica, Geneva, Arial, SunSans-Regular, sans-serif">Name</font><br>
<input type="text" size="75" name="name"> <br />
<font size="-1" face="Helvetica, Geneva, Arial, SunSans-Regular, sans-serif">Address</font><br>
<input type="text" size="75" name="address"><br />
<font size="-1" face="Helvetica, Geneva, Arial, SunSans-Regular, sans-serif">Phone Number</font><br>
<input type="text" size="75" name="phone number"><br />
<font size="-1" face="Helvetica, Geneva, Arial, SunSans-Regular, sans-serif">Email</font><br>
<input type="text" size="75" name="email"><br />
<font size="-1" face="Helvetica, Geneva, Arial, SunSans-Regular, sans-serif">Credentials</font><br>
<input type="text" size="75" name="credentials"><br />
<input type="submit" value="Submit"></div>
</form>
(Last edited by macfantn; Jul 17, 2007 at 08:33 PM. )
"I'm sick of following my dreams. I'm just going to ask them where they're goin', and hook up with them later"
     
Clinically Insane
Join Date: Jul 2005
Location: Vacation.
Status: Offline
Reply With Quote
Jul 12, 2007, 10:03 PM
 
You have four name="password" boxes?
Been inclined to wander... off the beaten track.
That's where there's thunder... and the wind shouts back.
     
Mac Elite
Join Date: Jun 2006
Status: Offline
Reply With Quote
Jul 12, 2007, 10:04 PM
 
I'm only just learning PHP and various other languages myself, but I'm pretty sure you'd need to be using PHP or something to execute the sending and formatting of an email based on whether someone has submitted data.

Right now you're using the mailto command, which is what people use in a "contact me" type of link. It is meant to open the person's mail app and fill in the Recipient line, and not to actually send the contents of a form to the person.
MBP 2.4/160/2/256
iMac 2.0/250/1/128
     
Mac Elite
Join Date: Apr 2005
Location: Nashville, TN
Status: Offline
Reply With Quote
Jul 12, 2007, 10:07 PM
 
i fixed the password thing, what should i do to correct the email problem?
"I'm sick of following my dreams. I'm just going to ask them where they're goin', and hook up with them later"
     
Clinically Insane
Join Date: Jul 2005
Location: Vacation.
Status: Offline
Reply With Quote
Jul 12, 2007, 10:16 PM
 
Originally Posted by macfantn View Post
i fixed the password thing, what should i do to correct the email problem?
Looks like a CGI, not PHP, thing to me. Most ISPs and hosts will have free CGI scripts for sending email from forms. Check your host's help site.
Been inclined to wander... off the beaten track.
That's where there's thunder... and the wind shouts back.
     
Mac Elite
Join Date: Apr 2005
Location: Nashville, TN
Status: Offline
Reply With Quote
Jul 12, 2007, 10:26 PM
 
i don't have a host yet, was thinking of using aplus.net

is there one that is better?
"I'm sick of following my dreams. I'm just going to ask them where they're goin', and hook up with them later"
     
Clinically Insane
Join Date: Jul 2005
Location: Vacation.
Status: Offline
Reply With Quote
Jul 12, 2007, 10:31 PM
 
<shrug>
Been inclined to wander... off the beaten track.
That's where there's thunder... and the wind shouts back.
     
Professional Poster
Join Date: Oct 2001
Status: Offline
Reply With Quote
Jul 12, 2007, 11:16 PM
 
Originally Posted by macfantn View Post
i don't have a host yet, was thinking of using aplus.net

is there one that is better?
Yeah, click the dreamhost link in my signature, it's really good and comes highly recommended. Plus if you use that link to register I'll get a referral, for which I will be most grateful to you. I've been with Dreamhost since 2003 and am very happy with their service, it's great deal, you get a lot for what you pay for.

The reason your form isn't working is because you action must point to a script that will send you the email, something along these lines: <form method="post" action="path/to/script.php"> ... </form>. Check out webmonkey on how to do forms, that website is somewhat old but it's still a great resource and is what I used to learn HTML many years ago.
     
Posting Junkie
Join Date: May 2001
Location: Portland, OR
Status: Offline
Reply With Quote
Jul 12, 2007, 11:24 PM
 
You can't send a form to an email address using HTML. You'll have to use a secondary solution, either a CGI or a PHP script, and you'll have to have it hosted on a server.
8 Core 2.8 ghz Mac Pro/GF8800/2 23" Cinema Displays, 3.06 ghz Macbook Pro
Once you wanted revolution, now you're the institution, how's it feel to be the man?
     
Baninated
Join Date: Mar 2005
Location: An asteroid remanent of Tatooine.
Status: Offline
Reply With Quote
Jul 13, 2007, 10:15 AM
 
Screw writing it yourself. Plenty of free scripts online.

This is the best one around

Secure PHP Form Mailer Script � Dagon Design

It's free, includes captcha, attachments, multiple recipients, secure and easy to configure.
     
Baninated
Join Date: Mar 2005
Location: An asteroid remanent of Tatooine.
Status: Offline
Reply With Quote
Jul 13, 2007, 10:18 AM
 
Originally Posted by macfantn View Post
i don't have a host yet, was thinking of using aplus.net

is there one that is better?
Dreamhost is good. Bluehost is better because there's less downtime, has faster support, every feature you could ask for and now has a script which speeds up and caches PHP.
     
mdc
Addicted to MacNN
Join Date: Feb 2003
Location: NY²
Status: Offline
Reply With Quote
Jul 13, 2007, 01:34 PM
 
1. Go through the formmail configuration wizard
2. Use this code for your form:

<style>input {
font-family: Helvetica, Geneva, Arial, SunSans-Regular, sans-serif;
}
</style>

<form action="YOUR FORMMAIL FILE" name="contact form" method="post">
<input type="hidden" value="YOUR EMAIL ADDRESS" name="recipients">
<input type="text" name="Name" value="Name" class="input"> <br />
<input type="text" name="Email" value="Email" class="input"> <br />
<input type="text" name="Address" value="Address" class="input"> <br />
<input type="text" name="Phone Number" value="Phone Number" class="input"> <br />
<input type="text" name="Credentials" value="Credentials" class="input"> <br />

<input type="submit" value="Submit">
</form>

Put the style to /style part in your head of your html document and then put the rest where ever you want your form.
You'll notice that in the form I created the label for each text input is actually in the text block. You can change that by taking out the value="".

If you need anymore help, just ask.
     
   
Thread Tools
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -5. The time now is 06:02 AM.
All contents of these forums © 1995-2011 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.7 © 2000-2011, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.3.2