Jump to content

Getting mailto to work


Recommended Posts

Ok so you have a form that you want to submit the info to your email. In the action attribute of your form add this:

<form name="form1" method="post" action="mailto:myemail@domain.com">...

That's it!

Link to post
Share on other sites
Ok so you have a form that you want to submit the info to your email. In the action attribute of your form add this:
<form name="form1" method="post" action="mailto:myemail@domain.com">...

That's it!

It doesn't work...when people click submit it comes up with the Outlook or whatever E-mail thing they use but when they press send, it doesn't send me a E-Mail...
Link to post
Share on other sites

what browser are u using some just add a que to outlook to be sent on send receive. some open outlook ask u to hit send then adds a que. and about 5 percent of people it will actually send u an email. without hitting send receive. and like no people actually use outllok so u cant count on the send receive button being hit.

Link to post
Share on other sites

Ok, im guessing your host has PHP support? (I hope so)anyways, first create two pages,home.php and mail.phpHere is the body coding for home.php:

<form action="mail.php" method="POST">Your email adress:<input type="text" name="thereemail"><br>Subject:<input type="text" name="subject"><br>Email:<br><input type="textarea" name="email" heigth="10" width="30"><br><input type="submit" value="send email!"><br></form>

Here is the coding for mail.php:

<?php$subject = $_POST['subject']$email = $_POST['email']$there_email = $_POST['thereemail'] mail("youremail@domain.com","$subject","$email","From:$there_email");?>

There are a few minor adjustments need like:in mail.php change "youremail@domain.com" to whatever your email adress isother thigns like that..

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...