this is my php cut from a file called kt.php:
Code: Select all
<?php
$myemail = "bestill@notypo.no";
if (!isset($epost))
echo "Somebody Goofed $ip" ;
if(!isset($_POST['submit']))
{
else
{
if(!isset($_POST['navn']) || strlen($_POST['navn']) <= 0)
{
echo 'Error: You did not enter your name.<br />';
exit();
}
if(!isset($_POST['epost']) || strlen($_POST['epost']) <= 0)
{
echo 'Error: You did not enter your email address.<br />';
exit();
}
$todayis = date("l, j F, Y, g:i") ;
$subject = "Henvendelse fra notypo.no - fra kontaktsida" ;
$message = " $todayis [GST] \n
Navn: $navn \n
Adresse: $gateadresse \n
Poststed: $poststed \n
Telefon: $telefon \n
Epost: $epost ($visitormail)\n
Kommentarer: $kommentarer \n
Additional Info : IP = $ip \n
Browser Info: $httpagent \n
Referral : $httpref \n
";
$from = "From: $myemail\r\n";
if ($myemail != "")
mail($myemail, $subject, $message, $from);
?>and i have coming from the form like this:
<form name="kontakt" id="kontakt" method="post" action="kt.php">