Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

PHP Forum


You are currently viewing our PHP Forum as a guest. Please register to participate.
Login



Freelance Jobs

Reply
CSS Website contact form
Old 07-05-2008, 01:19 AM CSS Website contact form
Junior Talker

Posts: 4
Name: Roland Karoliny
Trades: 0
Hi guys, i have bought a template and changed it, but now i have problems with my contact form. i dont know how to make it work. have a look on the site please http://www.bracksconsulting.com/index-5.html

and this is my css code for the contact form. so where can i activate my submit button and make it send the page to me.


<div class="col_2">
<div class="indent">
<img src="images/t6_3.gif" alt="" class="title" /><br />
<form action="" enctype="multipart/form-data" id="form">
<div class="box">
<div class="col_box_1">
Your name:
<div class="div_input"><input name="name" type="text" id="name" />
</div>
E-mail address:
<div class="div_input"><input name="email" type="text" id="email" />
</div>
Phone:
<div class="div_input"><input name="phone" type="text" id="phone" />
</div>
</div>
<div class="col_box_2">
Your message:
<div><textarea name="message" cols="0" rows="0" id="message"></textarea>
</div>
</div>
<div class="clear"></div>
</div>
<div class="div_links"><a class="link_3" href="#" onclick="document.getElementById('form').reset()"> clear</a><img src="images/spacer.gif" alt="" height="1" width="15" /><a class="link_3" href="#" onclick="document.getElementById('form').submit()" >submit</a></div></form>
</div>
</div>
<div class="clear"></div>
</div>
</div>



Thank you
soulroll is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 07-05-2008, 04:27 AM Re: CSS Website contact form
chrishirst's Avatar
Missing! presumed drunk.

Posts: 42,385
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
Right here is what you need to edit.
<form action="path_to/serverside/code/that/sends/the/message.ext" enctype="multipart/form-data" id="form">
__________________
Chris. ->>
Please login or register to view this content. Registration is FREE
<<-

A foolish consistency is the hobgoblin of little minds
Thought for today:- Is SEO the only industry where all the cowboys are Indians?
chrishirst is online now
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 07-05-2008, 05:17 AM Re: CSS Website contact form
Junior Talker

Posts: 4
Name: Roland Karoliny
Trades: 0
but what should i put there in??? should i make a contact.php file and put the link there? but what should be in the contact.php ??? i googled some but they dont fiyt to my css contact form.
soulroll is offline
Reply With Quote
View Public Profile
 
Old 07-05-2008, 10:29 AM Re: CSS Website contact form
chrishirst's Avatar
Missing! presumed drunk.

Posts: 42,385
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
Quote:
Originally Posted by soulroll View Post
but what should i put there in??? should i make a contact.php file and put the link there? but what should be in the contact.php ??? i googled some but they dont fiyt to my css contact form.
If your hosting supports PHP then PHP it will be.
__________________
Chris. ->>
Please login or register to view this content. Registration is FREE
<<-

A foolish consistency is the hobgoblin of little minds
Thought for today:- Is SEO the only industry where all the cowboys are Indians?
chrishirst is online now
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 07-06-2008, 03:42 AM Re: CSS Website contact form
Junior Talker

Posts: 4
Name: Roland Karoliny
Trades: 0
yes it supports php and i tried a couple but no one did really work. could you guys please help me with one??? any idea??

thank you very much.
soulroll is offline
Reply With Quote
View Public Profile
 
Old 07-06-2008, 05:21 AM Re: CSS Website contact form
Skilled Talker

Posts: 71
Trades: 0
PHP Code:
<?php

if ($_POST) {
    
// set variables
    
$name $_POST['name'];
    
$email $_POST['email'];
    
$phone $_POST['phone'];
    
$message $_POST['message'];

    
// now you would email using the mail() function.
    // I've written most of the script for you, so now it's your turn to figure this out
    // If you have specific questions, ask them.

} else {
    echo 
'<div class="col_2">
<div class="indent">
<img src="images/t6_3.gif" alt="" class="title" /><br />
<form action="contact.php" method="post" enctype="multipart/form-data" id="form">
<div class="box">
<div class="col_box_1">
Your name:
<div class="div_input"><input name="name" type="text" id="name" />
</div>
E-mail address:
<div class="div_input"><input name="email" type="text" id="email" />
</div>
Phone:
<div class="div_input"><input name="phone" type="text" id="phone" />
</div>
</div>
<div class="col_box_2">
Your message:
<div><textarea name="message" cols="0" rows="0" id="message"></textarea>
</div>
</div>
<div class="clear"></div>
</div>
<div class="div_links"><a class="link_3" href="#" onclick="document.getElementById(\'form\').reset()"> clear</a><img src="images/spacer.gif" alt="" height="1" width="15" /><a class="link_3" href="#" onclick="document.getElementById(\'form\').submit()" >submit</a></div></form>
</div>
</div>
<div class="clear"></div>
</div>
</div>'
;
}

?>
You'll need to lookup how to mail things. Part of learning PHP or any other language, is to actually write some code. I've written the basics of your script, now all you need to do is mail it and then some optional (and recommended) form validation.

Might have a look at this: http://us.php.net/manual/en/function.mail.php
CrazeDizzleD is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to CSS Website contact form
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting 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 Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.24906 seconds with 12 queries