Commit 3d71e286697443eced2d3a8d3fc609971591a6eb

Authored by Eugeny Galkovskiy
1 parent 6db0323e

123

Showing 2 changed files with 10 additions and 3 deletions   Show diff stats
www-arktika/email.php
@@ -49,7 +49,7 @@ if(isset($_POST['name']) && !empty($_POST['name']) && isset($_POST['email']) && @@ -49,7 +49,7 @@ if(isset($_POST['name']) && !empty($_POST['name']) && isset($_POST['email']) &&
49 $mail->Subject = 'Промокод на сайт semena.in.ua'; 49 $mail->Subject = 'Промокод на сайт semena.in.ua';
50 //Read an HTML message body from an external file, convert referenced images to embedded, 50 //Read an HTML message body from an external file, convert referenced images to embedded,
51 //convert HTML into a basic plain-text alternative body 51 //convert HTML into a basic plain-text alternative body
52 - $mail->msgHTML(file_get_contents("list.php")); 52 + $mail->msgHTML(file_get_contents("list.php?promo=".$code.""));
53 $mail->send(); 53 $mail->send();
54 //send the message, check for errors 54 //send the message, check for errors
55 header('Location: http://arktika.semena.in.ua/'); 55 header('Location: http://arktika.semena.in.ua/');
www-arktika/list.php
1 <?php 1 <?php
2 - 2 + if(isset("$_GET['promo']")){
  3 + $code = $_GET['promo'];
3 ?> 4 ?>
4 <html><head> 5 <html><head>
5 <meta charset="utf-8"> 6 <meta charset="utf-8">
@@ -221,4 +222,10 @@ @@ -221,4 +222,10 @@
221 222
222 </td></tr></table> 223 </td></tr></table>
223 224
224 -</body></html>  
225 \ No newline at end of file 225 \ No newline at end of file
  226 +</body></html>
  227 +<?php
  228 +}
  229 +else{
  230 + header('Location: http://arktika.semena.in.ua/');
  231 +}
  232 +?>
226 \ No newline at end of file 233 \ No newline at end of file