$field_value) { if($field_name == "answer_out" || $field_name == "MAX_FILE_SIZE" || $field_name == "submit" || $field_name == "security_code" || $field_name == "answer_p" || $field_name == "enc") { } else { // run all submitted content through string checker removing any dangerous code $this_val = $field_value; $message .= $field_name.": ".$this_val."\n\n"; } } //ALLE VELDEN VAN HET FORMULIER WEERGEVEN (einde) //indien je niet automatisch alle velden van het formulier wil opnemen in de mail maar zelf wil bepalen hoe deze velden in de mail zullen voorkomen, kan je het volgende doen: // 1) Plaats in commentaar wat hierboven staat tussen ALLE VELDEN VAN HET FORMULIER WEERGEVEN (begin) en ALLE VELDEN... (einde) // 2) plaats vervolgens de regels hieronder uit commentaar en copieer er indien nodig extra regels bij, vraag ev. meer uitleg aan de leerkracht //$message.= "Naam: ".$_POST['voornaam']." " .$_POST['naam']."\n"; //$message.= "Emailadres: ".$_POST['email']."\n"; // invisible portion of the message body // insert two dashes in front of the MIME boundary $message = "This is a multi-part message in MIME format.\n\n" . "--{$mime_boundary}\n" . "Content-Type: text/plain; charset=\"iso-8859-1\"\n" . "Content-Transfer-Encoding: 7bit\n\n" . $message . "\n\n"; // process uploaded files foreach($_FILES as $userfile){ // store the file information to variables for easier access $tmp_name = $userfile['tmp_name']; $type = $userfile['type']; $name = $userfile['name']; $size = $userfile['size']; // if the upload succeeded, the file will exist if (file_exists($tmp_name)){ // check to make sure that it is an uploaded file and not a system file if(is_uploaded_file($tmp_name)){ // open the file for a binary read $file = fopen($tmp_name,'rb'); // read the file content into a variable $data = fread($file,filesize($tmp_name)); // close the file fclose($file); // now we encode it and split it into acceptable length lines $data = chunk_split(base64_encode($data)); } // now we'll insert a boundary to indicate we're starting the attachment // we have to specify the content type, file name, and disposition as // an attachment, then add the file content. // NOTE: we don't set another boundary to indicate that the end of the // file has been reached here. we only want one boundary between each file // we'll add the final one after the loop finishes. $message .= "--{$mime_boundary}\n" . "Content-Type: {$type};\n" . " name=\"{$name}\"\n" . "Content-Disposition: attachment;\n" . " filename=\"{$fileatt_name}\"\n" . "Content-Transfer-Encoding: base64\n\n" . $data . "\n\n"; } } // here's our closing mime boundary that indicates the last part of the message $message.="--{$mime_boundary}--\n"; // send the email @mail($email_it_to, $email_subject, $message, $headers); // doorsturen variabelen uit formulier naar bevestigingspagina bv. form2.php (via sessions) $_SESSION['aanspreektitel'] = $_POST['aanspreektitel']; $_SESSION['naam'] = $_POST['naam']; //$_SESSION['voornaam'] = $_POST['voornaam']; //voorbeeld om ook variabele voornaam door te sturen //NOSECURITY unset($_SESSION['security_code']); // redirect $redirect_to="form2.php"; header("Location: $redirect_to"); die(); //tot hier verwerking form //NOSECURITY } else { //geef hieronder tussen de aanhalingstekens de HTML-tekst die getoond dient te worden bij een invalide security code //NOSECURITY $foutboodschap='Sorry, u gebruikte een ongeldige security code.
'; //NOSECURITY } } ?> index
INFO






allianz

logoGenihome
brandverzekering op maat
klik voor meer info


logo
Genicar
autoverzekering op maat
klik voor meer info



 





Graag ontvangen wij al uw vragen en bemerkingen per telefoon, of via dit contactformulier:

 

Aanspreking