Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $sql = "INSERT INTO order_table (o_date, client_id, o_total) VALUES ('$date', $client_id, $order_total);
- if ($con->query($sql)) {
- $order_id = $con->insert_id;
- foreach ($order_lines as $order_line) {
- $sql = "INSERT INTO order_lines (pid, price, color, size, qty, subtotal, order_id) VALUES ($pid, $price, $color, $size, $qty, $subtotal, $order_id);
- if (!$con->query($sql)) {
- $error[] = $con->error;
- }
- }
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement