• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

hi everyone! in need of some help with a contact form for my family business


#1
Hi everyone,
im new to the site and to be honest quite a noob at web designing

iv knocked up a site for my families business and have stumbled at the last hurdle, which is why im after some professional guidance off you skilled designers with the contact form of the website

in design view i have the contact form all in place but i am really struggling in how to set up in code the form so once entered it will send to my email address

below is the code to my form on the site

Any help what so ever would be much apreciated and i thank you in advance for your time in helping this noob


< !-- content -->
<article id="content">
<div class="wrapper">
<section class="col1">
<h2 class="under">Contact The Sales Team</h2>
<p>*Contact form currently under construction please email directly*</p>
<form id="ContactForm" method="post">
<div>
<div class="wrapper">
<span>Your Name:</span>
<input type="text" class="input" >
</div>
<div class="wrapper">
<span>Your City:</span>
<input type="text" class="input" >
</div>
<div class="wrapper">
<span>Your E-mail:</span>
<input type="text" class="input" >
</div>
<div class="textarea_box">
<span>Your Message:</span>
<textarea name="textarea" cols="1" rows="1"></textarea>
</div><a href="#" onClick="document.getElementById('ContactForm').su bmit()">Send</a><a href="#" onClick="document.getElementById('ContactForm').re set()">Clear</a>
</div>
</form>
 

Corrosive

Moderator
Staff member
#2

Katedesign

Well-Known Member
#3
This could prove a useful site! I am trying to get to grips with php and whilst I have got something working on a client's site it's not perfect. Faffing about with some more scripts may help. I always seem to want to do something beyond my knowledge....
 

Corrosive

Moderator
Staff member
#6
I don't want to learn it...but maybe I need to (a bit!)
Lol, you have to be a 'special' kind of person to want to learn a programming language. I have a reasonable grasp of it, enough to be dangerous anyway but more out of necessity than any desire to live under a rock and be a programmer!
 
#7
Lol, you have to be a 'special' kind of person to want to learn a programming language. I have a reasonable grasp of it, enough to be dangerous anyway but more out of necessity than any desire to live under a rock and be a programmer!
I will have you know I have a nice humble abode under my rock!!

Stebeck check out the PHP bult in function mail();

It makes sending emails pretty easy although you need to get the headers right (plenty of examples online).

You can detect whether the form has been submitted using

if(isset($_POST["name_of_field"]))
{

}

isset is a built in function that returns if a 'variable' exists. It is your friend :icon_cheers:

This is the simplist way of doing it... there are nicer ways such as using AJAX etc but I don't want to confuse you. Not yet.
 
Last edited:
#8
Katedesign programming can be really fun :)

It does take a certain type of person though I agree. :crazy:

Do you like taking things apart and seeing how they work?