Guest User

purchase.php

a guest
Sep 20th, 2017
614
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 19.34 KB | None | 0 0
  1. <?php
  2.     require_once '../startsession.php';
  3.  
  4.     // Make sure the user is logged in before going any further.
  5.     if (!isset($_SESSION['user_id']))
  6.     {
  7.         $login_url = 'http://www.alloygatorspain.es/login.php';
  8.         header('Location: ' . $login_url);
  9.         exit();
  10.     }
  11.    
  12.     // Set the timezone
  13.     ini_set("date.timezone", "Europe/Madrid");
  14.     date_default_timezone_set('Europe/Madrid');
  15.    
  16.     // Define the € symbol as a constant for use in the invoices
  17.     define('EURO', chr(128));
  18.    
  19.     // PHP for the form
  20.     if (isset($_POST["submit"]))
  21.     {
  22.         $fullname = $_SESSION['fullname'];
  23.         $address = $_SESSION['address'];
  24.         $email = $_SESSION['email'];
  25.         $quantity = $_POST['quantity'];
  26.         $nie = $_SESSION['nie'];
  27.         $postcode = $_SESSION['postcode'];
  28.                
  29.         // Connect to the database
  30.         include '../connectvars.php';
  31.         $dbc = mysqli_connect(DB_HOST, DB_USER, DB_PASSWORD, DB_NAME);
  32.        
  33.         // Set the MySQL timezone
  34.         $query0 = "SET time_zone = 'Europe/Madrid'";
  35.         $query00 = "SET time_zone = '+01:00'";
  36.         $query000 = "SET @@session.time_zone = '+01:00'";
  37.         mysqli_query($dbc, $query0) or die("The time zone could not be set: " . mysqli_error($dbc));
  38.         mysqli_query($dbc, $query00) or die("The time zone could not be set: " . mysqli_error($dbc));
  39.         mysqli_query($dbc, $query000) or die("The time zone could not be set: " . mysqli_error($dbc));
  40.        
  41.  
  42.         // If each quantity field has been filled, add this order to the database, send the email and then clear the form
  43.         if (isset($_POST['quantity']))
  44.         {
  45.             /**************************************************************************************************************/
  46.             // QUERY 2
  47.             // Add the order to the orders database (order_id, ordered_by, status, ordered_at)
  48.             $query2 = "INSERT INTO orders (ordered_by, status, ordered_at) VALUES ('$fullname', 'To pay', NOW())";
  49.             mysqli_query($dbc, $query2) or die("The order could not be added to the orders database");
  50.            
  51.             $insertedOrderID = mysqli_insert_id($dbc);
  52.            
  53.            
  54.             /**************************************************************************************************************/
  55.             // QUERY 3
  56.             // Add the order to the order_details database (order_id, product_id, quantity)
  57.                 // Create an array to store the keys and values from the form
  58.                 $orderDetailsArray = array();
  59.                                                
  60.                 // Loop through each quantity from the POST, adding it to the orderDetailsArray
  61.                 foreach ($quantity as $key => $value)
  62.                 {
  63.                     $orderDetailsArray[] = "('$insertedOrderID', '$key', '$value')";
  64.                 }
  65.                
  66.                 $orderDetailsArray_str = implode(',', $orderDetailsArray);
  67.                
  68.                 // Perform the MySQL query
  69.                 $query3 = "INSERT INTO order_details (order_id, product_id, quantity) VALUES $orderDetailsArray_str";
  70.                 mysqli_query($dbc, $query3) or die("There was an error: " . mysqli_error($dbc));
  71.                    
  72.            
  73.             /**************************************************************************************************************/
  74.             // EMAIL 1: Email AGS the invoice
  75.             // Produce the PDF using FPDF
  76.             require '../fpdf/fpdf.php';
  77.                
  78.             class PDF extends FPDF
  79.             {
  80.                 //Page header
  81.                 function Header()
  82.                 {
  83.                     // Define the variables to be global so they can be accessed
  84.                     global $insertedOrderID, $nie, $fullname, $address, $postcode;
  85.                    
  86.                     // Logo
  87.                     $this->Image('../assets/images/agslogo.jpg', 10, 10, 0, 30);
  88.                    
  89.                     // Invoice Number
  90.                     $this->Cell(130);
  91.                     $this->SetTextColor(132, 189, 0);
  92.                     $this->SetFont('Arial', 'B', 14);
  93.                     $this->Cell(40, 10, 'FACTURA ' . $insertedOrderID . '');
  94.                     $this->Ln(2);
  95.                    
  96.                     // Add our details
  97.                     $this->Cell(130);
  98.                     $this->SetFont('Arial', 'I', 10);
  99.                     $this->Cell(40, 30, 'AlloyGatorSpain');
  100.                     $this->Ln(4);
  101.                     $this->Cell(130);
  102.                     $this->Cell(40, 30, 'EC23 Calle El Castillo');
  103.                     $this->Ln(4);
  104.                     $this->Cell(130);
  105.                     $this->Cell(40, 30, 'Urb La Heredia');
  106.                     $this->Ln(4);
  107.                     $this->Cell(130);
  108.                     $this->Cell(40, 30, 'Benahavis');
  109.                     $this->Ln(4);
  110.                     $this->Cell(130);
  111.                     $this->Cell(40, 30, '29679');
  112.                     $this->Ln(4);
  113.                     $this->Cell(130);
  114.                     $this->Cell(40, 30, 'CIF HERE');
  115.                     $this->Ln(10);
  116.                    
  117.                     // Add partner's details
  118.                     // Add NIE/CIF
  119.                     $this->Cell(40, 30, 'NIE/CIF: ' . $nie);
  120.                     $this->Ln(4);
  121.                     // Add name
  122.                     $this->Cell(40, 30, 'Nombre: ' . $fullname);
  123.                     $this->Ln(4);
  124.                     // Add address + postcode
  125.                     $this->Cell(40, 30, 'Dirección: ' . $address);
  126.                     $this->Ln(4);
  127.                     $this->Cell(40, 30, 'Código Postal: ' . $postcode);
  128.                     $this->Ln(12);
  129.                     // Add date
  130.                     $this->SetFont('Arial', 'I', 10);
  131.                     $date = date("F j, Y");
  132.                     $this->Cell(40, 30, 'Fecha: ' . $date);
  133.                     $this->SetDrawColor(0, 0, 0);
  134.                 }
  135.                
  136.                 // Page footer
  137.                 function Footer()
  138.                 {
  139.                     //Position at 1.5 cm from bottom
  140.                     $this->SetY(-15);
  141.                     //Arial italic 8
  142.                     $this->SetFont('Arial','I',8);
  143.                     //Page number
  144.                     $this->Cell(0,10,'Page '.$this->PageNo().'/{nb}',0,0,'C');
  145.                 }
  146.             }
  147.  
  148.             $pdf = new PDF();
  149.             $pdf->AddPage();
  150.             $pdf->AliasNbPages();
  151.             $pdf->SetAutoPageBreak(false);
  152.              
  153.             // Table header
  154.             $pdf->SetFillColor(132, 189, 0);
  155.             $pdf->setFont("Arial", "B", "12");
  156.             $pdf->SetTextColor(91, 103, 112);
  157.             $pdf->setXY(10, 90);
  158.             $pdf->Cell(35, 10, "Product ID", 1, 0, "L", 1);
  159.             $pdf->Cell(35, 10, "Quantity", 1, 0, "L", 1);
  160.             $pdf->Cell(35, 10, "Price (exc VAT)", 1, 0, "L", 1);
  161.             $pdf->Cell(35, 10, "VAT", 1, 0, "L", 1);
  162.             $pdf->Cell(35, 10, "Total", 1, 0, "L", 1);
  163.            
  164.             // Table body
  165.             $y = 100;
  166.             $x = 10;  
  167.             $pdf->setXY($x, $y);
  168.             $pdf->setFont("Arial", "", "12");
  169.             $query4 = "SELECT * FROM order_details INNER JOIN products ON order_details.product_id = products.product_id WHERE order_id = '$insertedOrderID'";
  170.             $query4result = mysqli_query($dbc, $query4) or die(mysqli_error($dbc));
  171.            
  172.             $quantityCount = 0;
  173.             $priceCount = 0;
  174.             $itemsToReorderArray = array();
  175.            
  176.             while ($row = mysqli_fetch_assoc($query4result))
  177.             {
  178.                 $stock = 0;
  179.                 $pdf->Cell(35, 8, $row['product_name'], 1);
  180.                 $pdf->Cell(35, 8, $row['quantity'], 1);
  181.                 $pdf->Cell(35, 8, EURO . number_format($row['price'] * 0.8 * $row['quantity'], 2), 1);
  182.                 $pdf->Cell(35, 8, EURO . number_format($row['price'] * 0.2 * $row['quantity'], 2), 1);
  183.                 $pdf->Cell(35, 8, EURO . number_format($row['price'] * $row['quantity'], 2), 1);
  184.                
  185.                 // Set the product ID and new stock level, then insert into the database
  186.                 $productId = $row['product_id'];
  187.                 $stock = $row['stock'] - $row['quantity'];
  188.                 $query5 = "UPDATE products SET stock = '$stock' WHERE product_id = '$productId'";
  189.                 mysqli_query($dbc, $query5) or die (mysqli_error($dbc));
  190.                
  191.                 // If the calculated stock is less than or equal to the reorder level, add the product to the
  192.                 // $itemsToReorderArray
  193.                 if ($stock <= $row['reorder_level'])
  194.                 {
  195.                     array_push($itemsToReorderArray, array($row["product_id"], $row["product_name"], $stock, $row["reorder_quantity"]));
  196.                 }
  197.                
  198.                 // Move to the next row down, setting the quantityCount and priceCount
  199.                 $y += 8;
  200.                 $quantityCount += $row['quantity'];
  201.                 $priceCount += ($row['price'] * $row['quantity']);
  202.                
  203.                 // Insert a page break if needed
  204.                 if ($y > 260)
  205.                 {
  206.                     $pdf->AddPage();
  207.                     $y = 40;   
  208.                 }
  209.                 $pdf->setXY($x, $y);
  210.             }
  211.                        
  212.             // For each item in the $itemsToReorderArray, email sales@alloygator.com ordering more stock
  213.             include "../PHPMailer-master/PHPMailerAutoload.php";
  214.             if (!empty($itemsToReorderArray))
  215.             {
  216.                 $mail3 = new PHPMailer();
  217.                 // Enable SMTP debugging
  218.                 $mail3->SMTPDebug = 0;
  219.                 // Set debugging output to be HTML (friendly)
  220.                 $mail3->Debugoutput = "html";                        
  221.                 // Set PHPMailer to use SMTP
  222.                 $mail3->isSMTP();
  223.                 // Set SMTP host name                          
  224.                 $mail3->Host = "sub5.mail.dreamhost.com";
  225.                 // Set this to true if SMTP host requires authentication to send email
  226.                 $mail3->SMTPAuth = true;                      
  227.                 // Provide username and password    
  228.                 $mail3->Username = "no-reply@alloygatorspain.es";                
  229.                 $mail3->Password = "Lukeonaldo07!";                          
  230.                 // If SMTP requires TLS encryption then set it
  231.                 $mail3->SMTPSecure = "tls";
  232.                 // Set TCP port to connect to
  233.                 $mail3->Port = 587;                                  
  234.                 // Set headers and content
  235.                 $mail3->From = "no-reply@alloygatorspain.es";
  236.                 $mail3->FromName = "AlloyGatorSpain";
  237.                 $mail3->addAddress("web@alloygatorspain.es", "Web - AlloyGatorSpain"); // TO DO Change to sales@alloygator.com
  238.                 $mail3->isHTML(true);
  239.                 $mail3->Subject = "Request for stock";
  240.                 // Get each product and its associated reorder quantity
  241.                 $mail3->Body = "Dear Sales, <br /><br />";
  242.                 $mail3->Body .= "Please could we order the following products:<br /><br />";
  243.                 $mail3->Body .= '<table style="border: 3px #000000; text-align: center;">';
  244.                 $mail3->Body .= "<thead>";
  245.                 $mail3->Body .= "<tr>";
  246.                 $mail3->Body .= "<th>Item</th>";
  247.                 $mail3->Body .= "<th>Required Quantity</th>";
  248.                 $mail3->Body .= "</tr>";
  249.                 $mail3->Body .= "</thead>";
  250.                 $mail3->Body .= "<tbody>";
  251.                 foreach ($itemsToReorderArray as $v)
  252.                 {
  253.                     $mail3->Body .= "<tr>";
  254.                     $mail3->Body .= "<td>{$v[1]}</td>";
  255.                     $mail3->Body .= "<td>{$v[3]}</td>";
  256.                     $mail3->Body .= "</tr>";
  257.                     // TO DO
  258.                     // For each item in the $itemsToReorderArray, add the reorder_quantity to the stock
  259.                     $quantityToInsert = $v[2] + $v[3];
  260.                     $query6 = "UPDATE products SET stock = '$quantityToInsert' WHERE product_id = '$v[0]'";
  261.                     $q6result = mysqli_query($dbc, $query6) or die(mysqli_error($dbc));
  262.                 }
  263.                 $mail3->Body .= "</tbody>";
  264.                 $mail3->Body .= "</table><br /><br />";
  265.                 $mail3->Body .= "Thanks,<br />";
  266.                 $mail3->Body .= "AlloyGatorSpain";
  267.                 // Send the email
  268.                 $mail3->send();
  269.             }
  270.            
  271.             // See how big the order is and set postage accordingly
  272.             // TO DO: Adjust postage for Balearics
  273.             if ($quantityCount >= 10)
  274.             {
  275.                 $postage = 14;
  276.             }
  277.             else
  278.             {
  279.                 $postage = 9;
  280.             }
  281.             // Add postage
  282.             $pdf->Cell(35, 8, "Postage", 1);
  283.             $pdf->Cell(35, 8, "1", 1);
  284.             $pdf->Cell(35, 8, EURO . number_format($postage * 0.8, 2), 1);
  285.             $pdf->Cell(35, 8, EURO . number_format($postage * 0.2, 2), 1);
  286.             $pdf->Cell(35, 8, EURO . number_format($postage, 2), 1);
  287.             $y += 8;
  288.             if ($y > 260)
  289.             {
  290.                 $pdf->AddPage();
  291.                 $y = 40;   
  292.             }
  293.             $pdf->setXY($x, $y);
  294.             // Blank row
  295.             $pdf->Cell(175, 8, "", 1);
  296.             $y += 8;
  297.             if ($y > 260)
  298.             {
  299.                 $pdf->AddPage();
  300.                 $y = 40;   
  301.             }
  302.             $pdf->setXY($x, $y);
  303.             // Total row
  304.             $pdf->Cell(70, 8, "TOTAL", 1);
  305.             $pdf->Cell(35, 8, EURO . number_format($priceCount * 0.8, 2), 1);
  306.             $pdf->Cell(35, 8, EURO . number_format($priceCount * 0.2, 2), 1);
  307.             $pdf->Cell(35, 8, EURO . number_format($priceCount, 2), 1);
  308.             $y += 16;
  309.             if ($y > 260)
  310.             {
  311.                 $pdf->AddPage();
  312.                 $y = 40;   
  313.             }
  314.             $pdf->setXY($x, $y);
  315.            
  316.             // Insert the rest of the body (our payment details, NIE/CIF)
  317.             $pdf->SetFont('Arial', 'B', 14);
  318.             $pdf->Cell(0, 15, 'Our payment details:', 0, 0, 'L', false);
  319.             $y += 8;
  320.             if ($y > 260)
  321.             {
  322.                 $pdf->AddPage();
  323.                 $y = 40;   
  324.             }
  325.             $pdf->setXY($x, $y);           
  326.             $pdf->SetFont('Arial', '', 12);
  327.             $pdf->Cell(0, 15, 'Sort code: 11-06-41', 0, 0, 'L', false);
  328.             $y += 8;
  329.             if ($y > 260)
  330.             {
  331.                 $pdf->AddPage();
  332.                 $y = 40;   
  333.             }
  334.             $pdf->setXY($x, $y);           
  335.             $pdf->SetFont('Arial', '', 12);
  336.             $pdf->Cell(0, 15, 'Account number: 12345678', 0, 0, 'L', false);
  337.             $y += 8;
  338.             if ($y > 260)
  339.             {
  340.                 $pdf->AddPage();
  341.                 $y = 40;   
  342.             }
  343.             $pdf->setXY($x, $y);
  344.             $pdf->SetFont('Arial', '', 12);
  345.             $pdf->Cell(0, 15, 'PayPal: lukecolli98@gmail.com', 0, 0, 'L', false);
  346.             $y += 8;
  347.             if ($y > 260)
  348.             {
  349.                 $pdf->AddPage();
  350.                 $y = 40;   
  351.             }
  352.             $pdf->setXY($x, $y);
  353.              
  354.             $doc = $pdf->Output('S');
  355.        
  356.            
  357.             // DEAL WITH THE EMAIL
  358.             $mail = new PHPMailer();
  359.             // Enable SMTP debugging
  360.             $mail->SMTPDebug = 0;
  361.             // Set debugging output to be HTML (friendly)
  362.             $mail->Debugoutput = "html";                              
  363.             // Set PHPMailer to use SMTP
  364.             $mail->isSMTP();
  365.             // Set SMTP host name                          
  366.             $mail->Host = "sub5.mail.dreamhost.com";
  367.             // Set this to true if SMTP host requires authentication to send email
  368.             $mail->SMTPAuth = true;                      
  369.             // Provide username and password    
  370.             $mail->Username = "no-reply@alloygatorspain.es";                
  371.             $mail->Password = "Lukeonaldo07!";                          
  372.             // If SMTP requires TLS encryption then set it
  373.             $mail->SMTPSecure = "tls";
  374.             // Set TCP port to connect to
  375.             $mail->Port = 587;                                  
  376.             // Set headers and content
  377.             $mail->From = "no-reply@alloygatorspain.es";
  378.             $mail->FromName = "AlloyGatorSpain";
  379.             $mail->addAddress("web@alloygatorspain.es", "Web - AlloyGatorSpain"); // Change to Ben and David
  380.             $mail->isHTML(true);
  381.             $mail->Subject = "Invoice " . $insertedOrderID;
  382.             $mail->Body = "A partner has ordered some more stock. The details are below. Once you receive payment, please mark the order as paid and then process the order. You will <strong>not</strong> receive a notification when the partner pays. A copy of the invoice is attached.";
  383.             $mail->AltBody = "A partner has ordered some more stock. The details are below. Once you receive payment, please mark the order as paid and then process the order. You will *not* receive a notification when the partner pays. A copy of the invoice is attached.";
  384.             // Add the attachment
  385.             $mail->AddStringAttachment($doc, 'invoice.pdf', 'base64', 'application/pdf');
  386.             // Send the email
  387.             if(!$mail->send())
  388.             {
  389.                 $result = '<div class="alert alert-danger">' . $lang['ERROR'] . '</div>';
  390.             }
  391.             else
  392.             {
  393.                 $result = '<div class="alert alert-success">' . $lang['PAY_FOR_ORDER'] . '</div>';
  394.             }
  395.            
  396.  
  397.             /**************************************************************************************************************/
  398.             // EMAIL 2: Email the partner the invoice
  399.            
  400.             $mail2 = new PHPMailer();
  401.             // Enable SMTP debugging
  402.             $mail2->SMTPDebug = 0;
  403.             // Set debugging output to be HTML (friendly)
  404.             $mail2->Debugoutput = "html";                              
  405.             // Set PHPMailer to use SMTP
  406.             $mail2->isSMTP();
  407.             // Set SMTP host name                          
  408.             $mail2->Host = "sub5.mail.dreamhost.com";
  409.             // Set this to true if SMTP host requires authentication to send email
  410.             $mail2->SMTPAuth = true;                      
  411.             // Provide username and password    
  412.             $mail2->Username = "no-reply@alloygatorspain.es";                
  413.             $mail2->Password = "Lukeonaldo07!";                          
  414.             // If SMTP requires TLS encryption then set it
  415.             $mail2->SMTPSecure = "tls";
  416.             // Set TCP port to connect to
  417.             $mail2->Port = 587;                                  
  418.             // Set headers and content
  419.             $mail2->From = "no-reply@alloygatorspain.es";
  420.             $mail2->FromName = "AlloyGatorSpain";
  421.             $mail2->addAddress("web@alloygatorspain.es", "Web - AlloyGatorSpain");
  422.             $mail2->isHTML(true);
  423.             $mail2->Subject = "Invoice " . $insertedOrderID;
  424.             $mail2->Body = $lang['EMAIL_BODY'];
  425.             // Add the attachment
  426.             $mail2->AddStringAttachment($doc, 'invoice.pdf', 'base64', 'application/pdf');
  427.             // Send the email
  428.             $mail2->send();
  429.         }
  430.     }
  431. ?>
  432.  
  433. <!DOCTYPE html>
  434. <html lang="en">
  435.     <head>
  436.         <?php
  437.             // Set page title
  438.             $page_title = "Purchase Products - AlloyGatorSpain";
  439.             // Everything inside HTML <head> tags
  440.             include '../includes/header.php';
  441.         ?> 
  442.     </head>
  443.    
  444.     <body>
  445.         <?php
  446.             // Page header (above navbar)
  447.             include '../includes/page_header.php';
  448.             // Navbar
  449.             include '../includes/navbar.php';
  450.             // Carousel
  451.             include '../includes/carousels/homeCarousel.php';
  452.         ?>
  453.  
  454.         <!-- ===== SPACER ===== -->
  455.         <br />  
  456.  
  457.         <!-- ===== PAGE CONTENT ===== -->
  458.         <div class="container text-center">
  459.             <!-- First row -->
  460.             <div class="row">
  461.                 <div class="col-sm-12">
  462.                     <h1><?php echo $lang['PURCHASE_TITLE']; ?></h1>
  463.                     <?php echo $lang['PURCHASE_1']; ?>
  464.                 </div>
  465.             </div>
  466.             <br />
  467.            
  468.             <!-- Second row -->
  469.             <div class="row">
  470.                 <!-- Order form -->
  471.                 <div class="col-sm-12">
  472.                     <form class="form-horizontal" role="form" method="post" action="">
  473.                         <div class="form-group">
  474.                             <div class="col-sm-12">
  475.                                 <?php
  476.                                     echo $result;      
  477.                                 ?> 
  478.                             </div>
  479.                         </div>
  480.  
  481.                         <?php
  482.                             // Connect to the database
  483.                             include '../connectvars.php';
  484.                             $dbc = mysqli_connect(DB_HOST, DB_USER, DB_PASSWORD, DB_NAME);
  485.  
  486.                             // Retrieve the products from MySQL
  487.                             $query = "SELECT * FROM products WHERE active = 1 ORDER BY product_id ASC";
  488.                             $data = mysqli_query($dbc, $query);
  489.  
  490.                             // Loop through the array of products, formatting it as a HTML table
  491.                             echo '<table class="table table-hover purchaseProductsTable">
  492.                                      <tr>
  493.                                         <th>' . $lang['PRODUCT_NAME'] . '</th>
  494.                                         <th>' . $lang['PRICE'] . '</th>
  495.                                         <th>' . $lang['DESCRIPTION'] . '</th>
  496.                                         <th>' . $lang['QUANTITY'] . '</th>
  497.                                         <th>' . $lang['COST'] . '</th>
  498.                                      </tr>
  499.                                 ';
  500.  
  501.                             while ($row = mysqli_fetch_array($data))
  502.                             {
  503.                                 // Display the data
  504.                                 echo '<tr>';
  505.                                     echo '<td id="product_name">' . $row['product_name'] . '</td>';
  506.                                     echo '<td id="price-holder">&euro;<span id="price">' . $row['price'] . '</span></td>';
  507.                                     echo '<td id="description">' . $row['description'] . '</td>';
  508.                                     echo '<td id="quantity1" oninput="calculate()"><input type="number" min="0" class="form-control" id="quantity" name="quantity['.$row['product_id'].']" placeholder="' . $lang['CHOOSE_QUAN'] . '"></td>';
  509.                                     echo '<td id="cost">';
  510.                         ?>
  511.                                     <script>
  512.                                         function calculate()
  513.                                         {
  514.                                             var price = parseFloat(document.getElementById('price').innerHTML);
  515.                                             var quantity = parseFloat(document.getElementById('quantity').value);
  516.                                             document.getElementById('cost').innerHTML = "€" + (price * quantity);                                    
  517.                                         }
  518.                                     </script>
  519.                         <?php
  520.                                     echo '</td>';
  521.                                 echo '</tr>';
  522.                             }
  523.                             echo '<tr>';
  524.                                 echo '<td></td>';
  525.                                 echo '<td></td>';
  526.                                 echo '<td></td>';
  527.                                 echo '<td><strong>Total:</strong></td>';
  528.                                 echo '<td id="total_cost">TOTAL</td>';
  529.                             echo '</tr>';
  530.                             echo '</table>';
  531.                         ?>
  532.                        
  533.                         <!-- SUBMIT -->
  534.                         <div class="form-group">
  535.                             <div class="col-sm-12">
  536.                                 <input id="submit" name="submit" type="submit" value="<?php echo $lang['SUBMIT_ORDER']; ?>" class="btn btn-primary">
  537.                             </div>
  538.                         </div>
  539.                     </form>
  540.                 </div>
  541.             </div>
  542.         </div>
  543.        
  544.         <!-- ===== SPACER ===== -->
  545.         <br />
  546.  
  547.         <?php
  548.             // Footer
  549.             include '../includes/footer.php';
  550.         ?>
  551.     </body>
  552. </html>
Add Comment
Please, Sign In to add comment