eenvoudig contact formulier mailfunctie werkt niet

Pagina: 1
Acties:
  • 306 views

Acties:
  • 0 Henk 'm!

  • KoRnboy112
  • Registratie: Februari 2004
  • Laatst online: 27-08 01:11
UPDATE: Heb een andere gevonden welke wel werkt topic kan dicht.

Ben echt een noob m.b.t. php dus aantal examples gedownload echter geen van alle mailen ze 8)7

Even zoals het nu is:

contact.php
<table width="400" border="0" align="center" cellpadding="3" cellspacing="1">
<tr>
<td><strong>Contact Form </strong></td>
</tr>
</table>

<table width="400" border="0" align="center" cellpadding="0" cellspacing="1">
<tr>
<td><form name="form1" method="post" action="send_contact.php">
<table width="100%" border="0" cellspacing="1" cellpadding="3">
<tr>
<td width="16%">Subject</td>
<td width="2%">:</td>
<td width="82%"><input name="subject" type="text" id="subject" size="50"></td>
</tr>
<tr>
<td>Detail</td>
<td>:</td>
<td><textarea name="detail" cols="50" rows="4" id="detail"></textarea></td>
</tr>
<tr>
<td>Name</td>
<td>:</td>
<td><input name="name" type="text" id="name" size="50"></td>
</tr>
<tr>
<td>Email</td>
<td>:</td>
<td><input name="customer_mail" type="text" id="customer_mail" size="50"></td>
</tr>
<tr>
<td> </td>
<td> </td>
<td><input type="submit" name="Submit" value="Submit"> <input type="reset" name="Submit2" value="Reset"></td>
</tr>
</table>
</form>
</td>
</tr>
</table>

send_contact.php
<?php

// Contact subject
$subject ="$subject";

// Details
$message="$detail";


// Mail of sender
$mail_from="$customer_mail";

// From
$header="from: $name <$mail_from>";


// Enter your email address
$to ='ik@mezelf.nl';

$send_contact=mail($to,$subject,$message,$header);


// Check, if message sent to your email
// display message "We've recived your information"
if($send_contact){
echo "We've recived your contact information";
}
else {
echo "ERROR";
}
?>

Wat gaat er verkeerd, ik krijg wel de bedankt pagina maar geen mail binnen.. Mogelijk word het al meteen als spam gezien?? Iemand suggesties

Acties:
  • 0 Henk 'm!

  • Creepy
  • Registratie: Juni 2001
  • Laatst online: 23:09

Creepy

Tactical Espionage Splatterer

Ik doe inderdaad je topic dicht, maar dat is niet omdat jij een oplossing gevonden hebt. Das is wel omdat je support op code van anderen niet hier moet halen, maar bij de bron waar je je code vandaan hebt. PRG draait om het zelf programmeren, niet omdat door ons te laten doen voor de door jouw gedownloade code. Dus of je daar op wilt letten als je de volgende keer een topic opent :)

"I had a problem, I solved it with regular expressions. Now I have two problems". That's shows a lack of appreciation for regular expressions: "I know have _star_ problems" --Kevlin Henney


Dit topic is gesloten.