PHP not emailing
i have put php script. when click on submit thank page appears, haven't received email yet. here code... ideas did wrong?
<?php
/* subject , email variables */
$emailsubject = 'request quote!';
$webmaster = 'heather@peaklaboratories.com' ;
/* gathering data variables */
$first_namefield= $_post['first_name'];
$last_namefield = $_post['last_name'];
$company_namefield = $_post['company_name'];
$company_addressfield = $_post['company_address'];
$company_cityfield = $_post['company_city'];
$company_state_provincefield = $_post['company_state_province'];
$company_countryfield = $_post['company_country'];
$company_zipfield = $_post['company_zip'];
$email_field = $_post['email'];
$phone_numberfield = $_post['phone_number'];
$install_locationfield = $_post['install_location'];
$install_addressfield = $_post['install_address'];
$install_cityfield = $_post['install_city'];
$install_statefield = $_post['install_state'];
$install_zipfield = $_post['install_zip'];
$install_countryfield = $_post['install_country'];
$applicationfield = $_post['application'];
$body = <<<eod
<br><hr><br>
first_name: $first_name <br>
last_name: $last_name <br>
company name: $company_name <br>
company address: $company_address <br>
company city: $company_city <br>
company state: $company_state_province <br>
company country: $company_country <br>
company zip: $company_zip <br>
email: $email <br>
phone number: $phone_number <br>
install company: $install_location <br>
install address: $install_address <br>
install city: $install_city <br>
install state: $install_state <br>
install country: $install_country <br>
application: $application <br>
eod;
$headers = "from: $email\r\n";
$headers .= "content-type: text/html\r\n";
$success = mail($webmaster, $emailsubject, $body, $headers);
/* results rendered html */
$theresults = <<<eod
<!doctype html public "-//w3c//dtd xhtml 1.0 transitional//en" "http://www.w3.org/tr/xhtml1/dtd/xhtml1-transitional.dtd">
<html xmlns="[http://www.w3.org/1999/xhtml | http://www.w3.org/1999/xhtml]" >
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<meta name="description" content="peak laboratories world leader in design , manufacture of specialty gas chromatography systems. our proven mercuric oxide , flame ionization (fid) detector technologies used many industries throughout world." />
<meta name="keywords" content="peak performer 1 rcp, peak performer 1 fid, peak performer 2 rcp, peak performer 1 pdd, flame ionization detector, reducing compound photometer, pulse discharge detector, gas chromatography system" />
<title>peak laboratories | contact us</title>
<link rel="stylesheet" type="text/css" href="/css/index.css" media="all" />
<script src="http://jqueryjs.googlecode.com/files/jquery-1.2.6.min.js" type="text/javascript"></script>
<link rel="stylesheet" href="/css/general.css" type="text/css" media="screen" />
<script src="/css/popup.js" type="text/javascript"></script>
<script type="text/javascript">
var _gaq = _gaq || [];
_gaq.push();
gaq.push();</p><p> (function() {<br> var ga = document.createelement('script'); ga.type = 'text/javascript'; ga.async = true;<br> ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';<br> var s = document.getelementsbytagname('script')[0]; s.parentnode.insertbefore(ga, s);<br> })();</p><p></script><br></head></p><p><body></p><p><br><div id="container"><br><div id="main"></p><p><br><div id="topband"></div><br> <br class="clearfloat" /><br> <div id="topbandcolors"></div>
<br class="clearfloat" />
<div id="logo-tagline_bg"></div>
<a href="/">
<img src="/images/peak_labs_logo.gif" id="peak_labs_logo" alt="peak laboratories logo" />
</a>
<div id="topgreen_band"></div>
<br class="clearfloat" />
<div id="left_column">
<!-- nav starts here ><br> <div id="leftnav_region"><br> <br> <ul id="flyout"><br> <li><a href="/"><b>home</b></a></li><br> <li><a href="/about_us/"><b>about us</b></a></li><br> <li><a href="/products/"><b>products</b><![if gte ie 7]><!></a><!<![endif]><br> <![if lte ie 6]><table><tr><td><![endif]><br> <ul><br> <li><a href="/products/performer_1tcd.html"><b>peak performer 1 tcd</b></a></li><br> <li><a href="/products/performer_1fid.html"><b>peak performer 1 fid</b></a></li><br> <li><a href="/products/performer_1rcp.html"><b>peak performer 1 rcp</b></a></li><br> <li><a href="/products/performer_1pdd.html"><b>peak performer 1 pdd</b></a></li><br> <li class="last"><a href="/products/performer_2rcp.html"><b>peak performer 2 rcp</b></a></li><br> </ul><br> <![if lte ie 6]></td></tr></table></a><![endif]><br> </li><br> <li><a href="/services/"><b>services</b></a></li> <br> <li><a href="/resources/"><b>resource library</b></a></li><br> <li><a class="current" href="/contact_us/"><b>contact us</b></a></li><br> </ul></p><p> </div><br><! nav ends here ><br> <br><! left ads starts here > <br> <div id="homepage_ads"><br> <p class="ad_title">phone contact</p><br> <img src="/images/horizontal_line.gif" width="166" height="6"><br /><br> <p class="ad_copy"><span class="bodycopy">please contact peak laboratories @ <strong>650-691-1267</strong></span>.</p><br> </div><br><! left ads starts here > </p><p></div><br> <div id="colwrap1"><br> <div id="subpage_image_banner"><br><! animation starts here ><br> <img src="/images/subpage_image_contact_us.jpg" width="625" height="169" alt="peak performer gas analysis" /></p><p><! animation ends here ><br> </div><br> <br class="clearfloat" /><br> <div id="breadcrumbtrail"><br><! breadcrumb starts here > <br> <p class="breadcrumb_text"><a href="/">home</a>&nbsp; // &nbsp;<strong>contact us</strong></p><br><! breadcrumb ends here > <br> </div><br> <br class="clearfloat" /><br> <div id="content_area"><br> <br><! content starts here > </p><p> <h1>thank you</h1><br> <br> <p class="introcopy"> </p><p><br>form submission confirmation. thank response. review information submitted , contact shortly.<br /><br /></p><p>-peak laboratories</p><br /><br /><br /><br /><br /><br /><br /><br> <p class="bodycopy">&nbsp;</p><br> <p class="bodycopy"><br /><br> <! content ends here ><br> <br> <br> </div><br> <br class="clearfloat" /></div><br> <div id="green_footer"></div><br> <br class="clearfloat" /><br> <div id="bottom_band_colors"></div><br> <br class="clearfloat" /><br> <div id="grey_footer"><br><! footer starts here ><br> </p><p><br><div class="grid"><br> <div class="grid-m1"></div><br> <div class="grid-c1"><br> <p class="footer_text"><strong><a href="/about_us/">about peak labs</a><br /><br> <a href="/services/">peak services</a><br /><br> <a href="/resources/">peak resources</a><br /><br> <a href="/contact_us/">contact us</a></strong></p><br> </div><br> <div class="grid-m2"></div><br> <div class="grid-c2"><br> <p class="footer_text"><strong>peak products</strong><br /><br> <a href="/products/performer_1tcd.html">peak performer 1 tcd</a><br /><br> <a href="/products/performer_1fid.html">peak performer 1 fid</a><br /><br> <a href="/products/performer_1rcp.html">peak performer 1 rcp</a><br /><br> <a href="/products/performer_1pdd.html">peak performer 1 pdd</a><br /><br> <a href="/products/performer_2rcp.html">peak performer 2 rcp</a><br /><br> </div><br> <br> <!
<div class="grid-m3"></div>
<div class="grid-c3">fadsfds
</div>
-->
<div class="grid-m4"></div>
<div class="grid-c4">
<p class="footer_contact_text"><strong>peak laboratoires, llc</strong><br />
2330 old middlefield way, #10 mtn. view, ca 94043-2452 usa<br />
tel: (650) 691-1267 / fax: (650) 691-1047<br />
<a href="mailto:peaklaboratories@aol.com">peaklaboratories@aol.com</a></p>
<p class="footer_text">© 2011 rights reserved.</p>
</div>
<br style="clear:both" />
</div>
</div>
<br class="clearfloat" /></div>
</div>
<center>
<div id="popupcontact" style="z-index:9999"><a id="popupcontactclose"><img src="/images/close_button.gif" width="18" height="20" border="0" alt="close window" /></a><iframe id="popupcontent" src="" width="100%" height="100%" id="frame"><p>your browser not support iframes.</p></iframe></div><div id="backgroundpopup"></div>
</center>
</body>
</html>
eod;
echo "$theresults";
?>
sorry, don't have time re-invent wheel @ moment.
read through earlier discussion , see if helps you.
http://forums.adobe.com/thread/912801
best of luck,
nancy o.
More discussions in Dreamweaver support forum
adobe
Comments
Post a Comment