Kontakt formulier
/*© Jasper Koops 2006
This file is part of Koops Mail Form.
Koops Mail Form is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
any later version.
Koops Mail Form is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Foobar; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
Last Modified 29-07-2006
support@koops-projects.com
*/
include("config.php");
include("language/$language.php");
error_reporting(0);
if ($language == "gr"){
header("Content-Type: text/html; charset=iso-8859-7");
}
if($_POST[op] != "ds"){
$display_block = "
$title
$welcome
"; } else { //check if all fields are filled in if(empty($_POST['username'])){ $display_block = "$name_empty
"; } else if(empty($_POST['subject'])){ $display_block = "$subject_empty
"; } elseif(empty($_POST['mailaddress'])){ $display_block = "$mailaddress_empty
"; } elseif(empty($_POST['message'])){ $display_block = "$message_empty
"; } else { $_POST['message'] = nl2br($_POST['message']); //create the message $msg = "$name:".$_POST['username']." \n
"; $msg .= "$subject: $_POST[subject]\n
"; $msg .= "$mailaddress: $_POST[mailaddress]\n
"; $msg .= "$date: $date_message\n
"; $msg .= "$message:
\n$_POST[message]\n\n\n
"; $msg .= "
IP: $ip\n"; $headers = 'MIME-Version: 1.0' . "\n"; $headers .= 'Content-type: text/html; charset=iso-8859-1' . "\n"; $headers .= 'From: <'.$recipent. "> \n"; $headers .= 'Reply-to: '.$_POST['mailaddress']; //send the message mail($recipent,$standard_subject,$msg,$headers); //show the filled in values $_POST['recipent'] = ucfirst($_POST['recipent']); $display_block = "
$your_name:
".$_POST['username']."
"; $display_block .= "
$subject:
".$_POST['subject']."
"; $display_block .= "
$your_mailaddress:
".$_POST['mailaddress']."
"; $display_block .= "
$message:
".$_POST['message']."
"; $display_block .= "$thanks
"; //please do not remove the line below $display_block .= "Karperput Ammerstol"; } } } ?>