Ushe123 Posted December 19, 2008 Share Posted December 19, 2008 Hi guys, I'm kinda new to the whole php thingy and my boss asked me to edit his contact form into a PHP one. I been looking upto the script of his contact.htm and pasted my contact.php into it really. It won't show the website but just some weird coding. Anyway here it is This is the code of my bosses website - contact.htm <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <!--Serif WebPlus 10 HTML Export--> <!--Supports HTML 4.01--> <meta name="Generator" content="Serif WebPlus 10.0.4.029"> <title>Contact opnemen</title> <script type="text/javascript"> function validate_form_1( form ) { if( form.elements['NAME'].value=="" ) { alert("Please give your name"); form.elements['NAME'].focus(); return false; } if(!ValidateEmail(form.elements['EMAIL'].value)) { alert("Ongeldig e-mailadres."); form.elements['EMAIL'].focus(); return false; } if( form.elements['COMMENT'].value=="" ) { alert("Please give your comment"); form.elements['COMMENT'].focus(); return false; } return true; } </script> <style type="text/css"> <!-- body {margin: 0px; padding: 0px;} .Platte-tekst-_web_-P { margin:0.0px 0.0px 0.0px 0.0px; text-align:center; font-weight:400; } .Platte-tekst-_web_-P0 { margin:0.0px 0.0px 0.0px 0.0px; text-align:left; font-weight:400; } .Platte-tekst-_web_-C { font-family:"Verdana", sans-serif; font-size:11.0px; line-height:1.18em; color:#ffffff; } .Platte-tekst-_web_-C0 { font-family:"Verdana", sans-serif; font-size:12.0px; line-height:1.17em; color:#800000; } .Standaard-C { font-family:"Times New Roman", serif; font-size:16.0px; line-height:1.25em; color:#800000; } --> </style> <script src="_wp_scripts/jsFlashVer.js" type="text/javascript"></script> <script type="text/javascript"><!-- var blankSrc = "_wp_scripts/blank.gif"; --></script> <script src="_wp_scripts/jspngfix.js" type="text/javascript"></script> <script src="_wp_scripts/jsValidation.js" type="text/javascript"></script> <script src="_wp_scripts/jsDetectBrowser.js" type="text/javascript"></script> <script src="_wp_scripts/jsMenus.js" type="text/javascript"></script> <script type="text/javascript"> <!-- var wp_menubar0 = new wp_menus(); wp_menubar0.m_bkgndcolor = '#800000'; wp_menubar0.m_bkgndcolorhl = '#ffffff'; wp_menubar0.m_textcolor = '#ffffff'; wp_menubar0.m_textcolorhl = '#800000'; wp_menubar0.m_bordercolor = '#800000'; wp_menubar0.m_bordersize = 1; wp_menubar0.m_fontsize = 12; wp_menubar0.m_imagearrow = '_wp_generated/wpfb75a85a.gif'; wp_menubar0.m_imagearrowhl = '_wp_generated/wp83bffb86.gif'; wp_menubar0.m_fontfamily = 'Arial,serif'; wp_menubar0.m_filterOpacity = 100; wp_menubar0.m_mozOpacity = 1.000000; wp_menubar0.m_delay = 500; wp_menubar0.m_itemlines = false; wp_menubar0.m_width = 0; wp_menubar0.m_acStack.type = 0; wp_menubar0.m_acStack.m_showbelow = true; wp_menubar0.m_acStack.m_showright = true; wp_menubar0.m_acStack.gap = 1; wp_menubar0.m_acStack.bordergap = 1; wp_menubar0.BeginMenu("wp_menubar0_info.htm_2"); wp_menubar0.AddLink("wp_menubar0_info.htm_2_0","Lokaties",'lokaties.htm',null,'_self'); wp_menubar0.EndMenu(); wp_menubar0.BeginMenu("wp_menubar0_party_catering.htm_2"); wp_menubar0.AddLink("wp_menubar0_party_catering.htm_2_0","Broodjes",'broodjes.htm',"wp_menubar0_broodjes.htm_3",'_self'); wp_menubar0.AddLink("wp_menubar0_party_catering.htm_2_1","Koude Buffetten",'koude buffetten.htm',"wp_menubar0_koudebuffetten.htm_3",'_self'); wp_menubar0.EndMenu(); wp_menubar0.BeginMenu("wp_menubar0_broodjes.htm_3"); wp_menubar0.AddLink("wp_menubar0_broodjes.htm_3_0","Broodjes Assortiment Standaard",'broodjes_ass_stand.htm',null,'_self'); wp_menubar0.EndMenu(); wp_menubar0.BeginMenu("wp_menubar0_luxe_hapjes.htm_3"); wp_menubar0.AddLink("wp_menubar0_luxe_hapjes.htm_3_0","Koude hapjes",'koude_hapjes.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_luxe_hapjes.htm_3_1","Warme hapjes",'warme_hapjes.htm',null,'_self'); wp_menubar0.EndMenu(); wp_menubar0.BeginMenu("wp_menubar0_warme_bufetten.htm_3"); wp_menubar0.AddLink("wp_menubar0_warme_bufetten.htm_3_0","Oosters",'oosters.htm',"wp_menubar0_oosters.htm_4",'_self'); wp_menubar0.AddLink("wp_menubar0_warme_bufetten.htm_3_1","Italliaans",'italliaans.htm',"wp_menubar0_italliaans.htm_4",'_self'); wp_menubar0.AddLink("wp_menubar0_warme_bufetten.htm_3_2","Amerikaans",'amerikaans.htm',"wp_menubar0_amerikaans.htm_4",'_self'); wp_menubar0.AddLink("wp_menubar0_warme_bufetten.htm_3_3","Mexicaans",'mexicaans.htm',"wp_menubar0_mexicaans.htm_4",'_self'); wp_menubar0.AddLink("wp_menubar0_warme_bufetten.htm_3_4","Hollands",'hollands.htm',"wp_menubar0_hollands.htm_4",'_self'); wp_menubar0.AddLink("wp_menubar0_warme_bufetten.htm_3_5","Grieks",'grieks.htm',"wp_menubar0_grieks.htm_4",'_self'); wp_menubar0.EndMenu(); wp_menubar0.BeginMenu("wp_menubar0_oosters.htm_4"); wp_menubar0.AddLink("wp_menubar0_oosters.htm_4_0","Pagina 36",'pagina36.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_oosters.htm_4_1","Pagina 37",'pagina37.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_oosters.htm_4_2","Pagina 38",'pagina38.htm',null,'_self'); wp_menubar0.EndMenu(); wp_menubar0.BeginMenu("wp_menubar0_italliaans.htm_4"); wp_menubar0.AddLink("wp_menubar0_italliaans.htm_4_0","Pagina 39",'pagina39.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_italliaans.htm_4_1","Pagina 40",'pagina40.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_italliaans.htm_4_2","Pagina 41",'pagina41.htm',null,'_self'); wp_menubar0.EndMenu(); wp_menubar0.BeginMenu("wp_menubar0_amerikaans.htm_4"); wp_menubar0.AddLink("wp_menubar0_amerikaans.htm_4_0","Pagina 42",'pagina42.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_amerikaans.htm_4_1","Pagina 43",'pagina43.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_amerikaans.htm_4_2","Pagina 44",'pagina44.htm',null,'_self'); wp_menubar0.EndMenu(); wp_menubar0.BeginMenu("wp_menubar0_mexicaans.htm_4"); wp_menubar0.AddLink("wp_menubar0_mexicaans.htm_4_0","Pagina 45",'pagina45.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_mexicaans.htm_4_1","Pagina 46",'pagina46.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_mexicaans.htm_4_2","Pagina 47",'pagina47.htm',null,'_self'); wp_menubar0.EndMenu(); wp_menubar0.BeginMenu("wp_menubar0_hollands.htm_4"); wp_menubar0.AddLink("wp_menubar0_hollands.htm_4_0","Pagina 48",'pagina48.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_hollands.htm_4_1","Pagina 49",'pagina49.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_hollands.htm_4_2","Pagina 50",'pagina50.htm',null,'_self'); wp_menubar0.EndMenu(); wp_menubar0.BeginMenu("wp_menubar0_grieks.htm_4"); wp_menubar0.AddLink("wp_menubar0_grieks.htm_4_0","Pagina 51",'pagina51.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_grieks.htm_4_1","Pagina 52",'pagina52.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_grieks.htm_4_2","Pagina 53",'pagina53.htm',null,'_self'); wp_menubar0.EndMenu(); wp_menubar0.BeginMenu("wp_menubar0_koudebuffetten.htm_3"); wp_menubar0.AddLink("wp_menubar0_koudebuffetten.htm_3_0",""De Opening"",'de_opening.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_koudebuffetten.htm_3_1",""Bourgondiër"",'bourgondier.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_koudebuffetten.htm_3_2",""Atlantis"",'atlantis.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_koudebuffetten.htm_3_3",""Bourgondiër Exclusief"",'bourgondier_exclusief.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_koudebuffetten.htm_3_4",""Atlantis Exclusief"",'atlantis_exclusief.htm',null,'_self'); wp_menubar0.EndMenu(); wp_menubar0.BeginMenu("wp_menubar0_barbecues.htm_3"); wp_menubar0.AddLink("wp_menubar0_barbecues.htm_3_0",""Barbecue Basic"",'barbecue_basic.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_barbecues.htm_3_1",""Barbecue Exclusive"",'barbecue_exclusive.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_barbecues.htm_3_2",""Barbecue High Exclusive"",'barbecue_high_exclusieve.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_barbecues.htm_3_3",""Barbecue Fish"",'barbecue_fish.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_barbecues.htm_3_4",""Barbecue Stuart Little"",'barbecue_stuart_little.htm',null,'_self'); wp_menubar0.EndMenu(); wp_menubar0.BeginMenu("wp_menubar0_thema_feesten.htm_3"); wp_menubar0.AddLink("wp_menubar0_thema_feesten.htm_3_0",""Boeren Feest"",'boeren_feest.htm',null,'_self'); wp_menubar0.EndMenu(); wp_menubar0.BeginMenu("wp_menubar0_dranken.htm_3"); wp_menubar0.AddLink("wp_menubar0_dranken.htm_3_0","Bieren",'bieren.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_dranken.htm_3_1","Wijnen",'wijnen.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_dranken.htm_3_2","Gedestileerd",'gedestileerd.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_dranken.htm_3_3","Frisdranken",'frisdranken.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_dranken.htm_3_4","Sappen",'sappen.htm',null,'_self'); wp_menubar0.AddLink("wp_menubar0_dranken.htm_3_5","Warme dranken",'warme_dranken.htm',null,'_self'); wp_menubar0.EndMenu(); //--> </script> </head> <body link="#480000" vlink="#c67f7f" alink="#ef7f7f" text="#000000" style="background: #ffffff; height:800px;"> <center><div style="position:relative;width:800px;"> <div style="position:absolute; left:46px; top:203px; width:710px; height:33px;"> <img src="_wp_generated/wp19258088.png" width="710" height="33" border="0" id="tg_1" name="tg_1" title="" alt="wp19258088.png" onload="OnLoadPngFix()"></div> <div style="position:absolute; left:46px; top:756px; width:710px; height:33px;"> <img src="_wp_generated/wp19258088.png" width="710" height="33" border="0" id="tg_54" name="tg_54" title="" alt="wp19258088.png" onload="OnLoadPngFix()"></div> <div id="txt_42" style="position:absolute; left:50px; top:767px; width:700px; height:17px;-moz-box-sizing:border-box;box-sizing:border-box; overflow:hidden;"> <P class="Platte-tekst-_web_-P"><span class="Platte-tekst-_web_-C">© 2008 All-<wbr>In Catering Solutions ®</span></P> </div> <div id="vid_3" style="position:absolute; left:50px; top:0px; width:700px; height:200px;"> <script language="JavaScript" type="text/javascript"> var hasReqestedVersion = DetectFlashVer(8, 0, 0); if (hasReqestedVersion) { AC_FL_RunContent( "src", "Slide in 2 Images?CompanyName=All-In%20Catering%20Solutions&line1=Stationsstraat%2014&line2=6026%20CV%20%20MAARHEEZE&line3=tel:%200495-588222&scheme1=0x800000&scheme2=0x800000&Pic1URL=Img0509.jpg&Pic2URL=borden.jpg&Pic3URL=", "play", "true", "loop", "false", "width", "700", "height", "200", "salign", "C", "scale", "ExactFit", "id", "vid_3", "quality", "High", "wmode", "transparent", "bgcolor", "#FFFFFF", "name", "vid_3", "type", "application/x-shockwave-flash", 'codebase', 'http://fpdownload.macromedia.com/get/flashplayer/current/swflash.cab', "pluginspage", "http://www.macromedia.com/go/getflashplayer" ); } else { var alternateContent = 'An old version of the Flash plugin was detected. <strong><a href="http://www.macromedia.com/go/getflash/">Please upgrade your Flash plugin.</a></strong>'; document.write(alternateContent); } </script> </div> <div style="text-align:left; position:absolute; left:50px; top:205px;"> <a href="index.htm" target="_self"><img alt="" id="wp_menubar0_0" src="_wp_generated/wp4b8ac6dc.png" style="border:0;width:100px;height:28px;" onMouseOver="wp_MenuItemOver('wp_menubar0_0',wp_menubar0,null);" onMouseOut="wp_MenuItemOut('wp_menubar0_0',wp_menubar0);" onload="OnLoadPngFix();"></a><a href="info.htm" target="_self"><img alt="" id="wp_menubar0_1" src="_wp_generated/wp9677edfa.png" style="border:0;width:100px;height:28px;" onMouseOver="wp_MenuItemOver('wp_menubar0_1',wp_menubar0,'wp_menubar0_info.htm_2');" onMouseOut="wp_MenuItemOut('wp_menubar0_1',wp_menubar0);" onload="OnLoadPngFix();"></a><a href="party_catering.htm" target="_self"><img alt="" id="wp_menubar0_2" src="_wp_generated/wpe369be26.png" style="border:0;width:100px;height:28px;" onMouseOver="wp_MenuItemOver('wp_menubar0_2',wp_menubar0,'wp_menubar0_party_catering.htm_2');" onMouseOut="wp_MenuItemOut('wp_menubar0_2',wp_menubar0);" onload="OnLoadPngFix();"></a><a href="contact.htm" target="_self"><img alt="" id="wp_menubar0_3" src="_wp_generated/wp417c391a.png" style="border:0;width:100px;height:28px;" onMouseOver="wp_MenuItemOver('wp_menubar0_3',wp_menubar0,null);" onMouseOut="wp_MenuItemOut('wp_menubar0_3',wp_menubar0);" onload="OnLoadPngFix();"></a><a href="voorwaarde.htm" target="_self"><img alt="" id="wp_menubar0_4" src="_wp_generated/wp7b8e566b.png" style="border:0;width:100px;height:28px;" onMouseOver="wp_MenuItemOver('wp_menubar0_4',wp_menubar0,null);" onMouseOut="wp_MenuItemOut('wp_menubar0_4',wp_menubar0);" onload="OnLoadPngFix();"></a> <script type="text/javascript"> <!-- wp_menubar0.InitElement('wp_menubar0_0','_wp_generated/wp4b8ac6dc.png','_wp_generated/wpd0cd1876.png'); wp_menubar0.InitElement('wp_menubar0_1','_wp_generated/wp9677edfa.png','_wp_generated/wp6e0c5cea.png'); wp_menubar0.InitElement('wp_menubar0_2','_wp_generated/wpe369be26.png','_wp_generated/wpa0fdd1b5.png'); wp_menubar0.InitElement('wp_menubar0_3','_wp_generated/wp417c391a.png','_wp_generated/wpe4273588.png'); wp_menubar0.InitElement('wp_menubar0_4','_wp_generated/wp7b8e566b.png','_wp_generated/wp5bb1e50b.png'); //--> </script> </div> <div style="position:absolute; left:50px; top:256px; width:700px; height:359px;"> <img src="_wp_generated/wp74dc7995.png" width="700" height="359" border="0" id="qs_84" name="qs_84" title="" alt="wp74dc7995.png" onload="OnLoadPngFix()"></div> <div style="position:absolute; left:50px; top:615px; width:700px; height:143px;"> <img src="_wp_generated/wp1b1705b1.png" width="700" height="143" border="0" id="qs_95" name="qs_95" title="" alt="wp1b1705b1.png" onload="OnLoadPngFix()"></div> <form id="form_1" name="Contactopnemen" onSubmit="return validate_form_1(this)" action="mailto:[email protected]" method="post" target="_self" enctype="application/x-www-form-urlencoded"> <div id="txt_2" style="position:absolute; left:75px; top:325px; width:41px; height:14px;-moz-box-sizing:border-box;box-sizing:border-box; overflow:hidden;"> <label for="edit_1"><P class="Platte-tekst-_web_-P0"><span class="Platte-tekst-_web_-C0">Naam</span></P> </label> </div> <div style="position:absolute; left:404px; top:325px; width:150px; height:22px; text-align:left;"> <input type="text" id="edit_1" name="NAME" size="20" maxlength="50" value=""> </div> <div id="txt_1" style="position:absolute; left:75px; top:355px; width:79px; height:14px;-moz-box-sizing:border-box;box-sizing:border-box; overflow:hidden;"> <label for="edit_2"><P class="Platte-tekst-_web_-P0"><span class="Platte-tekst-_web_-C0">E-<wbr>mailadres</span></P> </label> </div> <div style="position:absolute; left:404px; top:355px; width:150px; height:22px; text-align:left;"> <input type="text" id="edit_2" name="EMAIL" size="20" maxlength="100" value=""> </div> <div id="txt_3" style="position:absolute; left:75px; top:385px; width:73px; height:14px;-moz-box-sizing:border-box;box-sizing:border-box; overflow:hidden;"> <label for="text_1"><P class="Platte-tekst-_web_-P0"><span class="Platte-tekst-_web_-C0">Opmerking</span></P> </label> </div> <div style="position:absolute; left:404px; top:385px; width:200px; height:86px; text-align:left;"> <textarea id="text_1" rows="5" cols="22" name="COMMENT" style="height:100%"></textarea> </div> <div id="tekst_24" style="position:absolute; left:75px; top:479px; width:313px; height:22px;-moz-box-sizing:border-box;box-sizing:border-box; overflow:hidden;"> <label for="kzr_1"><P class="Platte-tekst-_web_-P0"><span class="Standaard-C">Wenst een Vrijblijvend een bestellijst te ontvangen?</span></P> </label> </div> <div style="position:absolute; left:404px; top:479px; width:15px; height:22px; text-align:left;"> <input type="radio" id="kzr_1" name="Bestellijst" VALUE="Bestellijst"> </div> <div id="tekst_25" style="position:absolute; left:75px; top:509px; width:182px; height:22px;-moz-box-sizing:border-box;box-sizing:border-box; overflow:hidden;"> <label for="inv_2"><P class="Platte-tekst-_web_-P0"><span class="Standaard-C">Gelieve uw adres in te vullen</span></P> </label> </div> <div style="position:absolute; left:410px; top:506px; width:197px; height:22px; text-align:left;"> <input type="text" id="inv_2" name="Adres" size="28" value=""> </div> <div style="position:absolute; left:77px; top:581px; width:127px; height:22px; text-align:left;"> <input type="reset" id="butn_2" value="Beginwaarden"> </div> <div style="position:absolute; left:214px; top:581px; width:105px; height:22px; text-align:left;"> <input type="submit" id="butn_1" value="Verzenden"> </div> </form> <div style="position:absolute; left:49px; top:256px; width:704px; height:46px;"> <img src="_wp_generated/wpa6bec274.png" width="704" height="46" border="0" id="tg_52" name="tg_52" title="" alt="wpa6bec274.png" onload="OnLoadPngFix()"></div> </div></center> </body> </html> And this is the contact.php I wrote myself <? // give email $mail_ontv = "MYEMAIL!!"; // if email is incorrect function checkmail($mail) { $email_host = explode("@", $mail); $email_host = $email_host['1']; $email_resolved = gethostbyname($email_host); if ($email_resolved != $email_host && eregi("^[0-9a-z]([-_.~]?[0-9a-z])*@[0-9a-z]([-.]?[0-9a-z])*\\.[a-z]{2,4}$",$mail)) $valid = 1; return $valid; } // If a field has no value, or has been filled in wrong. if (!$_POST['submit'] || $_POST['submit'] && (!$_POST['naam'] || !$_POST['mail'] || !checkmail($_POST['mail']) || !$_POST['msggs'] || !$_POST['onderwerp'])) { if ($_POST['submit'] && (!$_POST['naam'] || !$_POST['mail'] || !checkmail($_POST['mail']) || !$_POST['msggs'] || !$_POST['onderwerp'])) { echo "Je bent je naam, e-mail adres, onderwerp of bericht vergeten in te vullen. Ook kan het zijn "; echo "dat je een verkeerd e-mail adres hebt ingevuld.<p>"; } // form + tabel echo "<table border=\"0\" cellspacing=\"0\" cellpadding=\"0\">"; echo "<form method=\"POST\" ACTION=\"" . $_SERVER['PHP_SELF'] . "\">"; // name echo "<tr><td>Naam:</td></tr>"; echo "<tr><td><input type=\"text\" name=\"naam\" value=\"" . $_POST['naam'] . "\"></td></tr>"; // space echo "<tr><td> </td></tr>"; // mail echo "<tr><td>E-mail adres:</td></tr>"; echo "<tr><td><input type=\"text\" name=\"mail\" value=\"" . $_POST['mail'] . "\"></td></tr>"; // space echo "<tr><td> </td></tr>"; // mail echo "<tr><td>Onderwerp:</td></tr>"; echo "<tr><td><input type=\"text\" name=\"onderwerp\" value=\"" . $_POST['onderwerp'] . "\"></td></tr>"; // space echo "<tr><td> </td></tr>"; // mail echo "<tr><td>Bericht:</td></tr>"; echo "<tr><td><TEXTAREA name=\"msggs\" ROWS=\"6\" COLS=\"45\">" . htmlentities($_POST['msggs']) . "</TEXTAREA></td></tr>"; // space echo "<tr><td> </td></tr>"; // button echo "<tr><td> </td></tr>"; echo "<tr><td><input type=\"submit\" name=\"submit\" value=\"Versturen\"></td></tr>"; // close form + tabel echo "</form>"; echo "</table>"; } // send else { // set datum $datum = date("d.m.Y H:i"); // set ip $ip = $_SERVER['REMOTE_ADDR']; $inhoud_mail = "===================================================\n"; $inhoud_mail .= "Ingevulde contact formulier\n"; $inhoud_mail .= "===================================================\n\n"; $inhoud_mail .= "Naam: " . $_POST['naam'] . "\n"; $inhoud_mail .= "E-mail adres: " . $_POST['mail'] . "\n"; $inhoud_mail .= "Bericht:\n"; $inhoud_mail .= $_POST['msggs'] . "\n\n"; $inhoud_mail .= "Verstuurd op $datum via het ip " . $ip . "\n\n"; $inhoud_mail .= "===================================================\n\n"; // -------------------- // spambot protection // ------ // // ------ $headers = "From: " . $_POST['naam'] . " <" . $_POST['mail'] . ">"; $headers = stripslashes($headers); $headers = str_replace("\n", "", $headers); // Verwijder \n $headers = str_replace("\r", "", $headers); // Verwijder \r $headers = str_replace("\"", "\\\"", str_replace("\\", "\\\\", $headers)); // Slashes van quotes $_POST['onderwerp'] = str_replace("\n", "", $_POST['onderwerp']); // Verwijder \n $_POST['onderwerp'] = str_replace("\r", "", $_POST['onderwerp']); // Verwijder \r $_POST['onderwerp'] = str_replace("\"", "\\\"", str_replace("\\", "\\\\", $_POST['onderwerp'])); // Slashes van quotes mail($mail_ontv, $_POST['onderwerp'], $inhoud_mail, $headers); echo "<h1>Je e-mail is verstuurd</h1>"; echo "<p>Bedankt voor het versturen van een e-mail. Je zult snel een antwoord "; echo "krijgen indien dit nodig is.</p>"; echo "<p>We nemen alles serieus en zullen vertrouwelijk omgaan met de informatie "; echo "die we binnen krijgen. Je e-mail adres zal nooit aan derden worden verstrekt.</p>"; } ?> Link to comment https://forums.phpfreaks.com/topic/137755-php-contact-into-an-html/ Share on other sites More sharing options...
trq Posted December 19, 2008 Share Posted December 19, 2008 Your going to need to be alot more descriptive with your problem. Link to comment https://forums.phpfreaks.com/topic/137755-php-contact-into-an-html/#findComment-720028 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.