Compare commits
5 Commits
351acf87dd
...
6ac8e2354e
Author | SHA1 | Date |
---|---|---|
MarkHipe | 6ac8e2354e | |
RryAn05 | daae43768c | |
RryAn05 | a02f0667ff | |
RryAn05 | 4bc084358c | |
RryAn05 | 2f7eb29f43 |
|
@ -1,6 +1,6 @@
|
|||
<?php
|
||||
$_SESSION["is_test"]=true;
|
||||
$_SESSION["test_email_rcpt"]="";
|
||||
$_SESSION["sales_email"]="";
|
||||
$_SESSION["test_email_rcpt"]="stacyjoycemapano@gmail.com";
|
||||
$_SESSION["sales_email"]="stacyjoycemapano@gmail.com";
|
||||
$_SESSION["data_endpoint"]="api.obanana.shop";
|
||||
?>
|
|
@ -611,12 +611,14 @@ function popupAddToCart(product, productVendor, token, email, password, customer
|
|||
Unit Price: <span>${response.items[0].price}</span>
|
||||
</span>
|
||||
<span id="subtotal-${response._id}" class="subtotal-${response._id}">Subtotal: ${totalAmount}</span>
|
||||
<div class="qty-plus-minuses">
|
||||
<div class="qty-btn" onclick="qtyDecrement('${response._id}', '${response.items[0]._id}', true)">-</div>
|
||||
<input id="qty-input-${response.items[0]._id}" class="qty-input" type="number" name="ec_qtybtn" value="${productData.quantity}" oninput="handleQtyInput(this, '${response._id}', '${response.items[0]._id}', true)"/>
|
||||
<div class="qty-btn" onclick="qtyIncrement('${response._id}', '${response.items[0]._id}', true)">+</div>
|
||||
<!-- 02-16-2024 Stacy added style -->
|
||||
<div class="qty-plus-minuses" style="display:flex; overflow:visible; align-items:center; padding-top:10px;">
|
||||
<div class="qty-btn" style="color:#ffaa00; font-size:35px; padding-right:5px; cursor: pointer;" onclick="qtyDecrement('${response._id}', '${response.items[0]._id}', true)">-</div>
|
||||
<input style="width:100px; height:40px" id="qty-input-${response.items[0]._id}" class="qty-input" type="number" name="ec_qtybtn" value="${productData.quantity}" oninput="handleQtyInput(this, '${response._id}', '${response.items[0]._id}', true)"/>
|
||||
<div class="qty-btn" style="color:#ffaa00; font-size:30px; padding-left:5px; cursor: pointer;" onclick="qtyIncrement('${response._id}', '${response.items[0]._id}', true)">+</div>
|
||||
<a href="#" class="removeCart" onclick="deleteOrder('${response._id}')"><i class="ecicon eci-trash" style="padding:20px; opacity:70%"></i></a>
|
||||
</div>
|
||||
<a href="#" class="removeCart" onclick="deleteOrder('${response._id}')">x</a>
|
||||
<!-- 02-16-2024 Stacy added style -->
|
||||
</div>
|
||||
`;
|
||||
getLatestOrders()
|
|
@ -1092,7 +1092,7 @@ if ($_SESSION["userId"] <> "") {
|
|||
<!-- raymart added js link feb 14 2024 -->
|
||||
<?php
|
||||
if ($_SESSION["is_test"]==true) {
|
||||
echo '<script src="assets/js/tester3.js"></script>';
|
||||
echo '<script src="assets/js/tester5.js"></script>';
|
||||
} else {
|
||||
echo '<script src="assets/js/produc3.js"></script>';
|
||||
}
|
||||
|
|
|
@ -0,0 +1,42 @@
|
|||
<!-- 02-19-2024 Stacy created contact-seller-action.php -->
|
||||
<?php
|
||||
include "functions.php";
|
||||
|
||||
$cstm_email = $_SESSION['email'];
|
||||
$prd_name = $_POST['product_name'];
|
||||
$prd_qnty = $_POST['product_quantityf'];
|
||||
$message = $_POST['message'];
|
||||
$id = $_POST['product_id'];
|
||||
|
||||
|
||||
$response = contact_Seller(
|
||||
$cstm_email,
|
||||
$prd_name,
|
||||
$prd_qnty,
|
||||
$message,
|
||||
);
|
||||
|
||||
$array = json_decode($response,true);
|
||||
var_dump($array);
|
||||
// header("location: product-left-sidebar.php?id=$id");
|
||||
|
||||
# 02-20-2024 Stacy added message sent
|
||||
// $result = customerExists($_SESSION["email"]);
|
||||
if ($response) {
|
||||
$_SESSION["SuccessfullySent"] = "Message Sent Successfully";
|
||||
header("location: product-left-sidebar.php?id=$id");
|
||||
}
|
||||
|
||||
|
||||
#02-19-2024 Stacy added email to be sent to customer
|
||||
$response2 = contact_Inquirer(
|
||||
$cstm_email,
|
||||
);
|
||||
$array = json_decode($response2,true);
|
||||
var_dump($array);
|
||||
header("location: product-left-sidebar.php?id=$id");
|
||||
|
||||
// if ($response2) {
|
||||
// // $_SESSION["SuccessfullySent"] = "Message Sent Successfully";
|
||||
// header("location: contact-us.php");
|
||||
// }
|
|
@ -7,7 +7,7 @@ include "functions.php";
|
|||
$phone = $_POST['phonenumber'];
|
||||
$message = $_POST['message'];
|
||||
|
||||
$response = sendEmail(
|
||||
$response = sendEmail_obanana(
|
||||
$fName,
|
||||
$lName,
|
||||
$email,
|
||||
|
@ -20,10 +20,23 @@ include "functions.php";
|
|||
|
||||
|
||||
# 02-15-2024 Stacy added message sent
|
||||
$result = customerExists($_SESSION["email"]);
|
||||
|
||||
if ($result > 0) {
|
||||
$_SESSION["SuccessfullySent"] = "Message Sent Successfully";
|
||||
// $result = customerExists($_SESSION["email"]);
|
||||
if ($response) {
|
||||
$_SESSION["SuccessfullySent"] = "Message Sent Successfully";
|
||||
header("location: contact-us.php");
|
||||
}
|
||||
# 02-15-2024 Stacy added message sent
|
||||
|
||||
#02-19-2024 Stacy added email to be sent to customer
|
||||
$response2 = sendEmail_customer(
|
||||
$fName,
|
||||
$lName,
|
||||
$email,
|
||||
);
|
||||
$array = json_decode($response2,true);
|
||||
var_dump($array);
|
||||
header("location: contact-us.php");
|
||||
|
||||
if ($response2) {
|
||||
// $_SESSION["SuccessfullySent"] = "Message Sent Successfully";
|
||||
header("location: contact-us.php");
|
||||
}
|
|
@ -170,7 +170,7 @@
|
|||
echo " <script>
|
||||
setTimeout(function() {
|
||||
document.getElementById('alertSuccess').style.display = 'none';
|
||||
}, 5000);
|
||||
}, 10000);
|
||||
</script>";
|
||||
}
|
||||
?>
|
||||
|
|
|
@ -542,7 +542,6 @@ function sendEmail_obanana($fName, $lName, $email, $phone, $message)
|
|||
}
|
||||
|
||||
|
||||
|
||||
function sendEmail_customer($fName, $lName, $email)
|
||||
{
|
||||
// if($_SESSION["is_test"]==true && $_SESSION["test_email_rcpt"]!=""){
|
||||
|
@ -628,7 +627,7 @@ function contact_Seller($cstm_email, $prd_name, $prd_qnty, $message)
|
|||
"Name" => "Subscriber"
|
||||
]
|
||||
],
|
||||
"Subject" => "Obanana Contact Us Form",
|
||||
"Subject" => "Obanana Contact Seller Form",
|
||||
"TextPart" => "Greetings from Obanana!",
|
||||
"HTMLPart" => $msgto_seller
|
||||
]
|
||||
|
@ -688,7 +687,7 @@ function contact_Inquirer($cstm_email)
|
|||
"Name" => "Subscriber"
|
||||
]
|
||||
],
|
||||
"Subject" => "Obanana Contact Us Form",
|
||||
"Subject" => "Obanana Contact Seller Form",
|
||||
"TextPart" => "Greetings from Obanana!",
|
||||
"HTMLPart" => $msgto_inquirer
|
||||
]
|
||||
|
|
15
header.php
15
header.php
|
@ -386,13 +386,16 @@
|
|||
<div class="cart-price">
|
||||
<span class="subtotal-<?php echo $order['_id']; ?>">Subtotal: <?php echo $order['total_amount'] ?></span>
|
||||
</div>
|
||||
<div class="qty-plus-minuses">
|
||||
<div class="qty-btn" onclick="qtyDecrement('<?php echo $order['_id']; ?>' , '<?php echo $order['items'][0]['_id']; ?>')">-</div>
|
||||
<input id="qty-input-<?php echo $order['items'][0]['_id']; ?>" class="qty-input" type="number" name="ec_qtybtn" value="<?php echo $order['items'][0]['quantity']; ?>" oninput="handleQtyInput(this, '<?php echo $order['_id']; ?>', '<?php echo $order['items'][0]['_id']; ?>')" />
|
||||
<div class="qty-btn" onclick="qtyIncrement('<?php echo $order['_id']; ?>' , '<?php echo $order['items'][0]['_id']; ?>', false)">+</div>
|
||||
<!-- 02-16-2024 Stacy added style -->
|
||||
<div class="qty-plus-minuses" style="display:flex; overflow:visible; align-items:center; padding-top:10px;">
|
||||
<div class="qty-btn" style="color:#ffaa00; font-size:35px; padding-right:5px; cursor: pointer;" onclick="qtyDecrement('<?php echo $order['_id']; ?>' , '<?php echo $order['items'][0]['_id']; ?>')">-</div>
|
||||
<input style="width:100px; height:40px" id="qty-input-<?php echo $order['items'][0]['_id']; ?>" class="qty-input" type="number" name="ec_qtybtn" value="<?php echo $order['items'][0]['quantity']; ?>" oninput="handleQtyInput(this, '<?php echo $order['_id']; ?>', '<?php echo $order['items'][0]['_id']; ?>')" />
|
||||
<div class="qty-btn" style="color:#ffaa00; font-size:30px; padding-left:5px; cursor: pointer;" onclick="qtyIncrement('<?php echo $order['_id']; ?>' , '<?php echo $order['items'][0]['_id']; ?>', false)">+</div>
|
||||
<!-- <a class="remove">x</a> -->
|
||||
<!-- <a href="#" class="removeCart" onclick="deleteOrder('<?php #echo $order['_id']; ?>')">x</a> -->
|
||||
<a href="#" class="removeCart" onclick="deleteOrder('<?php echo $order['_id']; ?>')"><i class="ecicon eci-trash" style="padding:20px; opacity:70%"></i></a>
|
||||
</div>
|
||||
<!-- <a class="remove">x</a> -->
|
||||
<a href="#" class="removeCart" onclick="deleteOrder('<?php echo $order['_id']; ?>')">x</a>
|
||||
<!-- 02-16-2024 Stacy added style -->
|
||||
</div>
|
||||
</li>
|
||||
<?php
|
||||
|
|
|
@ -2060,7 +2060,7 @@ if ($_SESSION["userId"] <> "") {
|
|||
<!-- raymart added js feb 14, 2024-->
|
||||
<?php
|
||||
if ($_SESSION["is_test"]==true) {
|
||||
echo '<script src="assets/js/tester3.js"></script>';
|
||||
echo '<script src="assets/js/tester5.js"></script>';
|
||||
} else {
|
||||
echo '<script src="assets/js/produc3.js"></script>';
|
||||
}
|
||||
|
|
|
@ -249,6 +249,21 @@ if (isset($_GET['id'])) {
|
|||
<!-- Single product content Start -->
|
||||
<div class="single-pro-block">
|
||||
<div class="single-pro-inner">
|
||||
<!-- 02-20-2024 Stacy message sent pop-up -->
|
||||
<?php
|
||||
if (isset($_SESSION["SuccessfullySent"])) {
|
||||
echo '<div class="alert alert-success" id="alertSuccess" role="alert"; content-align:center;>';
|
||||
echo $_SESSION["SuccessfullySent"];
|
||||
echo '</div>';
|
||||
unset($_SESSION["SuccessfullySent"]);
|
||||
echo " <script>
|
||||
setTimeout(function() {
|
||||
document.getElementById('alertSuccess').style.display = 'none';
|
||||
}, 10000);
|
||||
</script>";
|
||||
}
|
||||
?>
|
||||
<!-- 02-20-2024 Stacy message sent pop-up -->
|
||||
<div class="row">
|
||||
<div class="single-pro-img">
|
||||
<div class="single-product-scroll">
|
||||
|
@ -494,7 +509,7 @@ foreach ($variation_details as $index => $variation) {
|
|||
<b class="mb-0">To:</b>
|
||||
</div>
|
||||
<div class="col-md-1">
|
||||
<span><?php echo $vendor_details['user_email'] ?></span>
|
||||
<span><?php echo $_SESSION["sales_email"] ?></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -516,7 +531,7 @@ foreach ($variation_details as $index => $variation) {
|
|||
</div>
|
||||
<div class="col-md-2 col-2">
|
||||
<div class="qty-plus text-center">
|
||||
<input class="qty-inputs" type="number" name="ec_qtybtn" value="<?php echo (!empty($product_details['minimum_order'])) ? $product_details['minimum_order'] : "1"; ?>" id="qty-input" min="<?php echo (!empty($product_details['minimum_order'])) ? $product_details['minimum_order'] : "1"; ?>" />
|
||||
<input class="qty-inputs" type="number" name="product_quantity" value="<?php echo (!empty($product_details['minimum_order'])) ? $product_details['minimum_order'] : "1"; ?>" id="qty-input" min="<?php echo (!empty($product_details['minimum_order'])) ? $product_details['minimum_order'] : "1"; ?>" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -525,21 +540,30 @@ foreach ($variation_details as $index => $variation) {
|
|||
<div class="text-information">
|
||||
<b class="text">DETAILED REQUIREMENTS</b>
|
||||
</div>
|
||||
<form action="">
|
||||
<label for="">Enter product details such as color,sizr,materials,etc. and other specification requirements to receive an accurate quote</label>
|
||||
<textarea name="" id="" cols="30" rows="5"></textarea>
|
||||
<!-- 02-19-2024 Stacy modified this block of code -->
|
||||
<form action="contact-seller-action.php" method="post">
|
||||
<label for="">Enter product details such as color,size,materials,etc. and other specification requirements to receive an accurate quote</label>
|
||||
<textarea name="message" id="" cols="30" rows="5"></textarea>
|
||||
<input name="product_name" type="hidden" value='<?php echo $product_details['product_name']; ?>'/>
|
||||
<input class="qty-inputs" type="hidden" name="product_quantityf" value="<?php echo (!empty($product_details['minimum_order'])) ? $product_details['minimum_order'] : "1"; ?>" id="qty-input" min="<?php echo (!empty($product_details['minimum_order'])) ? $product_details['minimum_order'] : "1"; ?>" />
|
||||
|
||||
<input name="product_id" type="hidden" value='<?php echo $product_details['_id']; ?>'/>
|
||||
|
||||
<!-- <input name="product_quantity" type="number"/> -->
|
||||
<div class="modal-footer">
|
||||
<button type="submit" class="btn btn-secondary" data-bs-dismiss="modal">Send</button>
|
||||
</div>
|
||||
</form>
|
||||
<!-- 02-19-2024 Stacy modified this block of code -->
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<!-- <div class="modal-footer">
|
||||
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">Send</button>
|
||||
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="ec-single-wishlist">
|
||||
<a class="ec-btn-group wishlist" title="Wishlist" onclick="wishlist()"><i class="fi fi-rr-heart"></i></a>
|
||||
</div>
|
||||
|
@ -794,12 +818,14 @@ foreach ($variation_details as $index => $variation) {
|
|||
Unit Price: <span>${response.items[0].price}</span>
|
||||
</span>
|
||||
<span id="subtotal-${response._id}" class="subtotal-${response._id}">Subtotal: ${totalAmount}</span>
|
||||
<div class="qty-plus-minuses">
|
||||
<div class="qty-btn" onclick="qtyDecrement('${response._id}', '${response.items[0]._id}', true)">-</div>
|
||||
<input id="qty-input-${response.items[0]._id}" class="qty-input" type="number" name="ec_qtybtn" value="${productData.quantity}" oninput="handleQtyInput(this, '${response._id}', '${response.items[0]._id}', true)"/>
|
||||
<div class="qty-btn" onclick="qtyIncrement('${response._id}', '${response.items[0]._id}', true)">+</div>
|
||||
<!-- 02-16-2024 Stacy added style -->
|
||||
<div class="qty-plus-minuses" style="display:flex; overflow:visible; align-items:center; padding-top:10px;">
|
||||
<div class="qty-btn" style="color:#ffaa00; font-size:35px; padding-right:5px; cursor: pointer;" onclick="qtyDecrement('${response._id}', '${response.items[0]._id}', true)">-</div>
|
||||
<input style="width:100px; height:40px" id="qty-input-${response.items[0]._id}" class="qty-input" type="number" name="ec_qtybtn" value="${productData.quantity}" oninput="handleQtyInput(this, '${response._id}', '${response.items[0]._id}', true)"/>
|
||||
<div class="qty-btn" style="color:#ffaa00; font-size:30px; padding-left:5px; cursor: pointer;" onclick="qtyIncrement('${response._id}', '${response.items[0]._id}', true)">+</div>
|
||||
<a href="#" class="removeCart" onclick="deleteOrder('${response._id}')"><i class="ecicon eci-trash" style="padding:20px; opacity:70%"></i></a>
|
||||
</div>
|
||||
<a href="#" class="removeCart" onclick="deleteOrder('${response._id}')">x</a>
|
||||
<!-- 02-16-2024 Stacy added style -->
|
||||
</div>
|
||||
`;
|
||||
getLatestOrders()
|
||||
|
@ -1471,6 +1497,7 @@ foreach ($variation_details as $index => $variation) {
|
|||
</section>
|
||||
<!-- Related Product end -->
|
||||
|
||||
|
||||
<!-- Footer Start -->
|
||||
<?php include "footer.php" ?>
|
||||
<!-- Footer Area End -->
|
||||
|
|
|
@ -901,7 +901,7 @@ if ($_SESSION["userId"] <> "") {
|
|||
<script src="assets/js/main.js"></script>
|
||||
<?php
|
||||
if ($_SESSION["is_test"]==true) {
|
||||
echo '<script src="assets/js/tester3.js"></script>';
|
||||
echo '<script src="assets/js/tester5.js"></script>';
|
||||
} else {
|
||||
echo '<script src="assets/js/produc3.js"></script>';
|
||||
}
|
||||
|
|
|
@ -846,7 +846,7 @@ if ($_SESSION["userId"] <> "") {
|
|||
<!-- raymart added js link feb 14 2024 -->
|
||||
<?php
|
||||
if ($_SESSION["is_test"]==true) {
|
||||
echo '<script src="assets/js/tester3.js"></script>';
|
||||
echo '<script src="assets/js/tester5.js"></script>';
|
||||
} else {
|
||||
echo '<script src="assets/js/produc3.js"></script>';
|
||||
}
|
||||
|
|
|
@ -768,10 +768,10 @@ if ($_SESSION["userId"] <> "") {
|
|||
<script src="assets/js/vendor/index.js"></script>
|
||||
<script src="assets/js/main.js"></script>
|
||||
<!-- raymart added link from js feb 14 2024 -->
|
||||
<!-- <script src="assets/js/tester3.js"></script> -->
|
||||
<!-- <script src="assets/js/tester5.js"></script> -->
|
||||
<?php
|
||||
if ($_SESSION["is_test"]==true) {
|
||||
echo '<script src="assets/js/tester3.js"></script>';
|
||||
echo '<script src="assets/js/tester5.js"></script>';
|
||||
} else {
|
||||
echo '<script src="assets/js/produc3.js"></script>';
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue