MOON
Server: Apache
System: Linux ip-208-109-13-31.ip.secureserver.net 3.10.0-1160.119.1.el7.tuxcare.els4.x86_64 #1 SMP Sat Aug 31 06:58:57 UTC 2024 x86_64
User: durgeshpandey215 (1013)
PHP: 8.1.29
Disabled: NONE
Upload Files
File: /home/durgeshpandey215/public_html/zeeroprice.skilladders.com/DELETE-product-responses.php
<? require "application_top.php";
require "protect.php";
?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Responses</title>
	<!-- Meta tag Keywords -->
	<meta name="viewport" content="width=device-width, initial-scale=1">
	<meta charset="utf-8">
	<meta name="keywords" content="" />
	<? require "scripts.php";?>
</head>

<body>
<? $pagename = "responses"; require "header.php";?>
<div class="w3-bar w3-medium">
  <a href="#" class="w3-bar-item w3-button w3-border w3-right noteicon"><i class="fa fa-lightbulb-o"></i> Help</a>
  <a href="<?=HTTP_SERVER;?>approvedResponses.php" class="w3-bar-item w3-button w3-border w3-right">Approved Responses</a>
</div>
	<div class="tip w3-border w3-card" style="display:none;">
	<span onclick="this.parentElement.style.display='none'" class="w3-button w3-large w3-display-topright">×</span>
	To approve a response click on "Sell Now" button. A notification with OTP will be sent to buyer to confirm transaction when he/she receives the delivery.
	On completion of delivery, your account will be credited instantly with the balance amount (if any).
	</div>
	<?
	$sqlmp = " * from orders_detail inner join products on orders_detail.pid = products.pid where orders_detail.sellerid=? and orders_detail.isSold=? order by orders_detail.id desc";
	$whereParams[] = $userid;
	$whereParams[] = 0;
	//---------------pagination BOF---------------------------------------
	$from_where = $sqlmp;
	//$whereParams[] = 0; required created above 
	$extra ="&extra=";
	$adjacents = 3;
	$limit = 10; 							//how many items to show per page
	$targetpage = $_SERVER['PHP_SELF']; 	//your file name  (the name of this file)
	require "pagination.php";
	?>
	<h1 class="heading">Customer Responses (<?=$total_pages;?>)</h1>
	<br/>
	<div class="w3-card w3-white w3-padding">
		<?if($total_pages){?>
		<div style="overflow-x:auto;">
		<table class="listingtable">
		<tr>
		<TH>Item (MRP)</TH><TH>Customer Name (Mobile)</TH>
		<TH>Zeero Price</TH>
		<TH>Status</TH>
		<TH>Date</TH>
		</tr>
		<?
		$productArr = array();
		$customerArr = array();
		foreach($rows as $rowod){
			if(!in_array($rowod['pid'],$productArr)){
			//get product details
			$db->where('pid',$rowod['pid']);
			$productArr[$rowod['pid']] = $db->getOne('products');
			}
			if(!in_array($rowod['userid'],$customerArr)){
			//get customer details
			$db->where('userid',$rowod['userid']);
			$customerArr[$rowod['userid']] = $db->getOne('register');
			}
			if(count($productArr)){
			$prdurl = HTTP_SERVER."buy-at-lowest-price/".friendlyURL($productArr[$rowod['pid']]["ititle"] ?? '')."_".encode($rowod["pid"]).".html";
			}else{
			$prdurl = "#";
			}
		?>
			<tr>
			<td style="text-align:center;">
			<a href="<?=$prdurl;?>"><img src="<?=HTTP_SERVER;?>images/products/<?=($productArr[$rowod['pid']]['pic1'] ?? "")? $productArr[$rowod['pid']]['pic1']:"default.jpg";?>" style="width:90px;height:90px;"/></a>
			<br/>
			<?=currSign($productArr[$rowod['pid']]['currency'] ?? "");?>. <?=$rowod['mrp'];?>
			</td>
			<td style="text-align:center;">
			<?=$customerArr[$rowod['userid']]['fullname'];?><br/>
			<a href="tel:<?=$customerArr[$rowod['userid']]['mobno'];?>">
			<img src="<?=HTTP_SERVER;?>/images/call.png" class="icons"/></a>
			</td>
			<td>
			<?=currSign($productArr[$rowod['pid']]['currency'] ?? "");?>. <?=$rowod['customercost'];?>
			<br/>
			<form action="<?=HTTP_SERVER;?>approveOrder.php?id=<?=encode($rowod['orderid']);?>" method="post" class="commonform">
			<input type="submit" class="submitbutton w3-btn w3-border w3-red" value="Sell Now"/>
			</form>
			</td>
			<td style="text-align:center;">
				<?=($rowod['isapproved'])? "Approved":"Pending";?>
				<!--<a href="<?=HTTP_SERVER;?>handle.php?action=odstatus&id=<?=encode($rowod['orderid']);?>&newstatus=<?=($rowod['isapproved'])? 0 : 1;?>" title="Click to <?=($rowod['isapproved'])? "Deactivate" : "Activate";?> ">-->
			</td>
			<td style="text-align:center;font-size:12px;">
			<?=date('d-M-Y',strtotime($rowod['postedon'] ?? ""));?><br/>
			<?=date('H:i:s',strtotime($rowod['postedon'] ?? ""));?></td>
			</tr>
		<?}?>
		</table>
		</div>
		<center><?=$pagination;?></center>
		
		<?}else{ ?><br/> No customer responses found<br/><br/><?}?>
		
	</div>
 <br/><br/>
	
<? require "footer.php";?>