Jump to content

HTML Form Help

- - - - -

This topic has been archived. This means that you cannot reply to this topic.
11 replies to this topic

#1
Chewie

Chewie

    Speaks fluent binary

  • Members
  • PipPipPipPipPipPipPipPip
  • 1,579 posts
Hello I would Like to Know how to make a forms action submit the info to my email, I know it involves a CGI script but I don't know how to create one, where to put it on my server or how to link it from my form to my email, please help thank you!

#!CrunchBang Linux ~$ apt-get into it | #!(Statler:R20101205): OpenBox | Like Linux?
“The cure for boredom is curiosity. There is no cure for curiosity.”


#2
Guest_Jordan_*

Guest_Jordan_*
  • Guests
The easiest way is to make the action mailto:your@email.com. IE:

<form action="mailto:you@email.com">....</form>


#3
Chewie

Chewie

    Speaks fluent binary

  • Members
  • PipPipPipPipPipPipPipPip
  • 1,579 posts

Jordan said:

The easiest way is to make the action mailto:your@email.com. IE:

<form action="mailto:you@email.com">....</form>

Yes, J-Man I know this method but that brings up an outlook doc, if the user has outlook up and running,I should've elaborated, I mean I would like to do it just by them clicking submit then showing them a page saying thank you for your form, blah blah blah.

you know?

#!CrunchBang Linux ~$ apt-get into it | #!(Statler:R20101205): OpenBox | Like Linux?
“The cure for boredom is curiosity. There is no cure for curiosity.”


#4
Guest_Jordan_*

Guest_Jordan_*
  • Guests
That method doesn't bring up their default email client. You are thinking of an emailto link. The method above will email you the raw data of the form so long as you have email setup on the server properly.

#5
WingedPanther

WingedPanther

    A spammer's worst nightmare

  • Moderators
  • 16,831 posts
The alternative will depend on what you're using on the server. PHP handles email differently from ASP or ColdFusion.
Programming is a branch of mathematics.
My CodeCall Blog | My Personal Blog

#6
Chewie

Chewie

    Speaks fluent binary

  • Members
  • PipPipPipPipPipPipPipPip
  • 1,579 posts
Hmmmm, mailto would be easier than, right?!
If so May I get an elaboration of it, if not both methods mentioned please?
:D

#!CrunchBang Linux ~$ apt-get into it | #!(Statler:R20101205): OpenBox | Like Linux?
“The cure for boredom is curiosity. There is no cure for curiosity.”


#7
jpiche

jpiche

    Newbie

  • Members
  • PipPip
  • 16 posts
Isn't using
action="mailto:you@email.com"
dangerous? I would never post a critical email address directly in html--one word, spam. If you have access to PHP, you can use the
mail
function to email data.

#8
Chewie

Chewie

    Speaks fluent binary

  • Members
  • PipPipPipPipPipPipPipPip
  • 1,579 posts
I do, but IDK PHP, any1 wanna help me out? =p I'm sort of in a time crunch here.

#!CrunchBang Linux ~$ apt-get into it | #!(Statler:R20101205): OpenBox | Like Linux?
“The cure for boredom is curiosity. There is no cure for curiosity.”


#9
Chewie

Chewie

    Speaks fluent binary

  • Members
  • PipPipPipPipPipPipPipPip
  • 1,579 posts
Speed Bump.

#!CrunchBang Linux ~$ apt-get into it | #!(Statler:R20101205): OpenBox | Like Linux?
“The cure for boredom is curiosity. There is no cure for curiosity.”


#10
jpiche

jpiche

    Newbie

  • Members
  • PipPip
  • 16 posts
Hey, if you need immediate help, just PM me. I might be able to help you out.

#11
Chewie

Chewie

    Speaks fluent binary

  • Members
  • PipPipPipPipPipPipPipPip
  • 1,579 posts

jpiche said:

Hey, if you need immediate help, just PM me. I might be able to help you out.

Thank you J for the help, still need some more learning though.

=+Rep-:-Ped though!

#!CrunchBang Linux ~$ apt-get into it | #!(Statler:R20101205): OpenBox | Like Linux?
“The cure for boredom is curiosity. There is no cure for curiosity.”


#12
Guest_Jordan_*

Guest_Jordan_*
  • Guests
<?php

$to      = 'nobody@example.com';

$subject = 'the subject';

$message = 'hello';

$headers = 'From: webmaster@example.com' . "\r\n" .

    'Reply-To: webmaster@example.com' . "\r\n" .

    'X-Mailer: PHP/' . phpversion();


mail($to, $subject, $message, $headers);

?>