HTML - contact us form

10 replies
  • WEB DESIGN
  • |
hello. i have a site in html and it has a contact us form. how do i program it to send the email to my email address. here's the code i have so far:
<h2>Contact Form</h2>
<div id="contact-form-row">
<form id="contact-form" method="post" class="form-validate" action="#">
<input type="text" name="name" value="Name:" class="contact-form-Text" onblur="this.value=!this.value?'Name :':this.value;" onclick="this.value='';" />
<input type="text" name="email" value="Email:" class="contact-form-Text" onblur="this.value=!this.value?'Email :':this.value;" onclick="this.value='';" />
<textarea name="text" class="contact-textarea" rows="" cols="" onblur="this.value=!this.value?'Message:':this.val ue;" onclick="this.value='';" >Message:</textarea>
<input type="submit" value="Subscribe" id="contact-form-submit" />
#contact #form #html
  • Profile picture of the author Fuze
    You need to use PHP.
    I suggest reading the following link first.
    PHP Mail
    {{ DiscussionBoard.errors[3941040].message }}
  • Profile picture of the author Toby Couchman
    Is your site just a plain html site?
    {{ DiscussionBoard.errors[3941393].message }}
  • Profile picture of the author Fuze
    It doesn't matter if it plain html or not, you can always implement PHP by changing the document type.
    {{ DiscussionBoard.errors[3941614].message }}
  • Profile picture of the author techwpblog
    i think in PHP this task is very easy..
    {{ DiscussionBoard.errors[3942231].message }}
    • Profile picture of the author harryhamlin
      Indeed...this is something which has to be done using PHP!!
      {{ DiscussionBoard.errors[3942286].message }}
      • Profile picture of the author thenefrit
        You need to pass the variables (content of the IDs) to the externail page (mail.php)

        in html file you have to make
        <form method="post" action="mail.php">
        <input type="text" id="name_of_id">
        </form>


        then in mail.php

        <?php
        $to
        = $_POST[name_of_id];


        mail($to, $subject, $message, $headers);
        ?>
        {{ DiscussionBoard.errors[3949395].message }}
  • Profile picture of the author tonymontana007
    it would be really easily if u program it in php.
    {{ DiscussionBoard.errors[3949472].message }}
  • Profile picture of the author jason2009
    yeah without PHP you can't do that
    {{ DiscussionBoard.errors[3951055].message }}
  • Profile picture of the author gokulvikas
    Hi,

    If you find any difficulties in doing it manually. Then create the form page using Simfatic Forms: create and maintain your forms in a breeze! .

    It's really superb software to work on it.
    {{ DiscussionBoard.errors[3951230].message }}
    • Profile picture of the author FreelanceScribe
      I use formmail.com. You have to build the form yourself but they handle all the forms processing and it saves you the problems of running CGI scripts or hassle with the installation and configuration.

      They provide a free trial account and a full account for about about $1/month.
      Signature

      Kindle author and freelance writer. Special offers on writing eBooks, manuals or reports. eBook: Facebook Advertising: "Strategies, Tactics, Tools & Tracking", http://www.amazon.com/dp/B00ADV5LT6. Amazon Author page http://amazon.com/author/alexbeckis.

      {{ DiscussionBoard.errors[3957826].message }}

Trending Topics