D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
proc
/
thread-self
/
root
/
home
/
shubmkcj
/
designpitara.com
/
admin
/
product
/
Filename :
update-product-details.php
back
Copy
<?php include("../include/config.php"); include("../include/sessionhandle.php"); include("../include/header.php"); $l_id = $_GET['id']; $sqlAssign1 = "SELECT * FROM `product` WHERE `product`.`id` ='$l_id'"; // echo $sqlAssign1; $resultAssign1 = mysqli_query($conn, $sqlAssign1); if (mysqli_num_rows($resultAssign1) > 0) { while($rows = mysqli_fetch_assoc($resultAssign1)) { $id = $rows['id']; $product_category_id = $rows['product_category_id']; $name = $rows['name']; $price = $rows['price']; $imgesa = $rows['imge']; $purl = $rows['url']; $details = $rows['details']; $meta_title = $rows['meta_title']; $meta_desc = $rows['meta_desc']; $meta_keyword = $rows['meta_keyword']; }} $sqlAssign12 = "SELECT * FROM `product_category` WHERE `product_category`.`id`='$product_category_id'"; // echo $sqlAssign1; $resultAssign12 = mysqli_query($conn, $sqlAssign12); if (mysqli_num_rows($resultAssign12) > 0) { while($rows2 = mysqli_fetch_assoc($resultAssign12)) { $pcategory_ids = $rows2['id']; $pg_category_name = $rows2['g_category_name']; } } ?> <style> #my_product ul li:nth-child(3) { background-color: #eb6a4e; } #my_product ul li:nth-child(3) a { color: #fff; } #my_product ul li:nth-child(3) a:hover { background-color: #eb6a4e; } #srkproperty_details .course-detailsa img { width: 100% !important; max-height: 250px !important; } </style> <script> window.onload = function() { document.getElementById('my_product').classList.add("active"); document.getElementById('my_product1').classList.add("in"); }; </script> <div class="small-header"> <div class="hpanel"> <div class="panel-body"> <div id="hbreadcrumb" class="pull-right"> <ol class="hbreadcrumb breadcrumb"> <li><a href="<?php echo $admin_baseurl . 'dashboard.php';?>">Dashboard</a></li> <li class="active"> <span>Product</span> </li> </ol> </div> <h2 class="font-light m-b-xs"> Update Product Details </h2> </div> </div> </div> <div class="content"> <div class="hpanel"> <div class="hpanel"> <div class="panel-heading hbuilt"> <div class="panel-tools"> <a class="showhide"><i class="fa fa-chevron-up"></i></a> <a class="fullscreen"><i class="fa fa-expand"></i></a> </div> Update Product Details </div> <div class="panel-body"> <form class="form-horizontal" action="execute-details.php" method="post" enctype="multipart/form-data"> <div class="form-group"> <div class="col-md-12"> <label class="control-label">Product Title</label> <input type="text" name="productName" class="form-control" placeholder="Product Title" value="<?php echo $name; ?>" required> </div> <div class="col-md-12"> <label class="control-label">Custom Url</label> <input type="text" name="custom_url" class="form-control" placeholder="Product custom Url" value="<?php echo $purl; ?>"> </div> <div class="col-md-6"> <label class="control-label">Select Category </label> <select name="product_categ_id" class="form-control" required> <option value="<?php echo $pcategory_ids;?>"> <?php echo $pg_category_name;?></option> <option value="" disabled>-- Select Product Category --</option> <?php $sql1m = "SELECT * FROM `product_category` WHERE `product_category`.`id` NOT IN ('$pcategory_ids') ORDER BY `product_category`.`g_category_name` ASC"; $result1m = mysqli_query($conn, $sql1m); if (mysqli_num_rows($result1m) > 0) { while($row1m = mysqli_fetch_assoc($result1m)) { $det_det_id = $row1m['id']; $g_category_name = $row1m['g_category_name']; ?> <option value="<?php echo $det_det_id?>"> <?php echo $g_category_name;?></option> <?php } } ?> </select> </div> <div class="col-md-6"> <label class="control-label">Product Price in Rupees</label> <input type="number" min="0" name="productPrice" class="form-control" placeholder="Product Price" required value="<?php echo $price; ?>"> </div> <div class="col-md-12"> <label class="control-label">Details</label> <textarea required class="textarea form-control " id="product_details" name="product_details" placeholder="Enter text ..." rows="15" data-height="100"><?php echo htmlspecialchars($details); ?></textarea> </div> <div class="col-md-6"> <label class="control-label">Product Image</label> <input type="file" id="file" class="form-control" name="image_a" multiple="multiple" accept="image/*" > </div> <div class="col-md-6"> <img src="<?php echo $admin_baseurl . 'product/upload/'. $imgesa;?>" style="width:100px;"> </div> <div class="col-md-12"><br> <label>Seo Keywords</label> <input name="keyword" class="form-control" placeholder="eg.Meta Keywords..." value="<?php echo $meta_keyword; ?>"> </div> <div class="col-md-12"> <label>Meta Title</label> <input name="meta_title" class="form-control" placeholder="Meta Title" value="<?php echo $meta_title; ?>"> </div> <div class="col-md-12"> <label>Meta Description</label> <input name="description" class="form-control" placeholder="Meta Description" value="<?php echo $meta_desc; ?>"> </div> <div class="col-md-12"> <div class="form-group" style="padding:0 20px;"> <br> <div class="text-right"> <input type="hidden" name="productId" value="<?php echo $l_id;?>"> <input type="hidden" name="product_images" value="<?php echo $imgesa;?>"> <button type="reset" class="btn btn-default">Cancel</button> <button type="submit" name="update_product_details" class="btn btn-primary">Submit</button> </div> </div> </div> </div> </form> </div> </div> </div> </div> <script> $(function() { CKEDITOR.replace('product_details', { height: 250, filebrowserUploadUrl: "<?php echo $admin_baseurl . 'product/ckupload.php'; ?>", filebrowserUploadMethod: 'form' }); }); </script> <?php include('../include/footer.php'); ?>