Current location: Hot Scripts Forums » Programming Languages » PHP » PHP Dropdown Display


PHP Dropdown Display

Reply
  #1 (permalink)  
Old 07-04-10, 06:35 PM
seungew seungew is offline
New Member
 
Join Date: Jun 2010
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
PHP Dropdown Display

Hello PHP gurus

I'm new to PHP and I just recently registered a website that I am going to be designing
with a form in it.

The host server that I registered with has a CGI-BIN , PHP, MySQL capability.

My problem is that I am trying to get the information from my simple HTML form emailed to my account as a text message and also it will also tell me which email address it came from.

This is my HTML code for my form :

<form method="post" action="../sendmail.php">
Email:
<input name="email" type="text" /><br />
Message:<br />
<textarea name="message" rows="15" cols="40">
</textarea><br />
<h2>Select Your Car</h2>
<p>Type:<br />
<select name="selType">
<option value="Porsche 911">Porshe 911</option>
<option value="Volkswagen Beetle">Volkswagen Beetle</option>
<option value="Ford Taurus">Ford Taurus</option>
</select>
</p>
<p>Color:<br />
<select name="selColor">
<option value="blue">blue</option>
<option value="yellow">yellow</option>
<option value="red">red</option>
</select>
</p>
<p/>

<input type="submit" />
</form>


Now for my PHP file, I've got only the email address to display who its from in my email but I can't seem to get the information from the dropdown to display in my email. Here is the PHP code:

<?php
$email = $_REQUEST['email'] ;
$message = $_REQUEST['message'] ;
$type = $_POST['selType'];
$color=$_POST['selColor'];
mail( "name@mydomain.com", "Feedback Form Results",
$message,"From:$email");
header( "Location: http://www.mydomain.com/thankyou.html" );
?>


Please help if you can. I appreciate you time on this.

Thanks in advance
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 2 (0 members and 2 guests)
 
Thread Tools
Display Modes

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 Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] PHP form, display wrong in email. RichyRich38 PHP 2 03-27-09 10:13 AM
PHP Programmers India - PHP Developers India - PHP Web Developers - Hire PHP Programmers jaysmith2110 PHP 0 03-18-09 12:06 AM
Display irc room list php and user registration pjirc buckd31 PHP 0 09-11-08 08:31 AM
Tally and Display Data from SQL database using PHP? watchcat Script Requests 0 11-19-07 02:09 PM
100 Web Templates & 10 PHP Scripts for sale! HostersUK.co.uk General Advertisements 0 01-10-04 12:31 AM


All times are GMT -5. The time now is 08:16 AM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.