// Initializ database connection etc require_once('../includes/firstcode.php'); // Order posted ? if( isset( $_POST["article"] ) && is_numeric( $_POST["article"]) ) { if( $article = $obj_shop->GetArticle( $_POST["article"] ) ) { $obj_shop->AddOrder(); // Send mail $message = ""; $message.= "Beste " . $_POST["name"] . ",\n\n"; $message.= "Bedankt voor uw bestelling bij RijksTextiel!\n"; $message.= "Hierbij bevestigen wij uw bestelling van ". $_POST["amount"] ." maal het artikel " . $article->A_Title ." a ". sprintf("%.2f", $article->A_Price) ." euro.\n"; $message.= "De totaalprijs van uw bestelling komt hiermee uit op ". sprintf("%.2f", $article->A_Price * $_POST["amount"] ) ." euro.\n\n"; $message.= "Wij verzoeken u dit bedrag over te maken op rekeningnummer ....... onder vermelding van .......\n\n"; $message.= "Met vriendelijke groet,\n"; $message.= "RijksTextiel"; require_once('../classes/class.phpmailer.php'); $mail = new PHPMailer(); $mail->AddReplyTo("h.benthem@home.nl","RijksTextiel"); $mail->SetFrom('RijksTextiel@benthem.nu', 'RijksTextiel'); $mail->AddAddress(addslashes($_POST["email"]),addslashes($_POST["name"])); $mail->AddBCC("h.benthem@home.nl","Haiko Benthem"); $mail->Subject = "Bevestiging bestelling"; $mail->Body = $message; $mail->Send(); } header("location: producten.php?succes"); exit; } $id = isset($_GET["id"]) && is_numeric($_GET["id"]) ? $_GET["id"] : 0; $article = $obj_shop->GetArticle( $id ); if( $article === false ) { // Non existent article header("location: producten.php"); exit; } // Resize to maximum width of 325px $width = $article->I_Width; $height= $article->I_Height; if( $width > 315 ) { $height = floor(315 / $width * $height); $width = 315; } // Header & Menu require_once('header.php'); ?>
|
OMSCHRIJVINGBESTELLEN€ 0.00
|
![]() ![]() ![]() |