D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
proc
/
thread-self
/
root
/
home
/
shubmkcj
/
designpitara.com
/
admin
/
Filename :
execute.php
back
Copy
<?php error_reporting(0); include("include/config.php"); ########################################################################################## if(array_key_exists("update_admin_profile",$_REQUEST)){ $admin_username = $_POST['admin_userNames']; echo $admin_username . "<br>"; $sqlAssign1 = "select * from `admin_more_info` WHERE `user_name` = '$admin_username'"; $resultAssign1 = mysqli_query($conn, $sqlAssign1); if (mysqli_num_rows($resultAssign1) > 0) { $i=1; while($rowAssign1 = mysqli_fetch_assoc($resultAssign1)) { $logo = $rowAssign1['logo_img']; $fav = $rowAssign1['fav_img']; $logo_sticky = $rowAssign1['logo_sticky']; } } // echo "update_admin_profile" . " $sqlAssign1 " . $username; die; $admin_wesite_name = $_POST['website_name']; $admin_owner_name = $_POST['owner_name']; $admin_phone = $_POST['phone']; $admin_phone_op = $_POST['phone_op']; $admin_email = $_POST['email']; $admin_email_op = $_POST['email_op']; $admin_address = $_POST['address']; $admin_about_us = mysqli_real_escape_string($conn,$_POST['ckeditor_about_us']); $admin_Mission = mysqli_real_escape_string($conn,$_POST['ckeditor_Mission']); $admin_Vision = mysqli_real_escape_string($conn,$_POST['ckeditor_Vision']); $admin_strength = mysqli_real_escape_string($conn,$_POST['ckeditor_strength']); @$fb_link = $_POST['fb_link']; @$youtube_link = $_POST['youtube_link']; @$instagram_link = $_POST['instagram_link']; @$linkedin_link = $_POST['linkedin_link']; // $admin_userName = $_POST['admin_userName']; $p_meta_keywords = mysqli_real_escape_string($conn,$_POST['p_meta_keywords']); $p_meta_desc = mysqli_real_escape_string($conn,$_POST['p_meta_desc']); $meta_title = mysqli_real_escape_string($conn,$_POST['meta_title']); // forlogo if(isset($_FILES['image_a']['name'])) { $fileName1 = time().$_FILES["image_a"]["name"]; $fileTmpLoc1 = $_FILES["image_a"]["tmp_name"]; $fileType1 = $_FILES["image_a"]["type"]; $fileSize1 = $_FILES["image_a"]["size"]; $fileErrorMsg1 = $_FILES["image_a"]["error"]; $kaboom1 = explode(".", $fileName1); $fileExt1 = end($kaboom1); $moveResult1 = move_uploaded_file($fileTmpLoc1, "upload/$fileName1"); } if(empty($_FILES['image_a']['name'])) { $fileName1 = $logo; } // for sticky logo if(isset($_FILES['image_c']['name'])) { $fileName21 = time().$_FILES["image_c"]["name"]; $fileTmpLoc21 = $_FILES["image_c"]["tmp_name"]; $fileType21 = $_FILES["image_c"]["type"]; $fileSize21 = $_FILES["image_c"]["size"]; $fileErrorMsg21 = $_FILES["image_c"]["error"]; $kaboom21 = explode(".", $fileName21); $fileExt2 = end($kaboom21); $moveResult21 = move_uploaded_file($fileTmpLoc21, "upload/$fileName21"); } if(empty($_FILES['image_c']['name'])) { $fileName21 = $logo_sticky; } //for fav icon if(isset($_FILES['image_b']['name'])) { $fileName2 = time().$_FILES["image_b"]["name"]; $fileTmpLoc2 = $_FILES["image_b"]["tmp_name"]; $fileType2 = $_FILES["image_b"]["type"]; $fileSize2 = $_FILES["image_b"]["size"]; $fileErrorMsg2 = $_FILES["image_b"]["error"]; $kaboom2 = explode(".", $fileName2); $fileExt2 = end($kaboom2); $moveResult2 = move_uploaded_file($fileTmpLoc2, "upload/$fileName2"); } if(empty($_FILES['image_b']['name'])) { $fileName2 = $fav; } $query = "UPDATE `admin_more_info` SET `website_name` = '$admin_wesite_name', `phone` = '$admin_phone', `op_phone` = '$admin_phone_op', `email` = '$admin_email', `op_email` = '$admin_email_op', `address` = '$admin_address', `logo_img` = '$fileName1', `logo_sticky` = '$fileName21', `fav_img` = '$fileName2', `about_us` = '$admin_about_us', `mission` = '$admin_Mission', `vision` = '$admin_Vision', `strength` = '$admin_strength', `facebook` = '$fb_link', `youtube` = '$youtube_link', `linkedin` = '$linkedin_link', `insta` = '$instagram_link', `meta_title` = '$meta_title', `p_meta_keywords` = '$p_meta_keywords', `p_meta_desc` = '$p_meta_desc' where (`admin_more_info`.`user_name` = '$admin_username');"; // echo $query; die; $query .= "UPDATE `user_login` SET `name` = '$admin_owner_name', `email` = '$admin_email', `phone` = '$admin_phone' where (`username` = '$admin_username');"; //echo $query; die; $result = mysqli_multi_query($conn, $query); // if (mysqli_query($conn, $query)) { if($result){ header("location:profile.php"); // echo '<script>location.replace("profile.php")</script>'; } else { // include('include/error-modal.php'); echo "qu faild to update data"; } mysqli_close($conn); } ################################################################################### ################################################################################### //lead inquiry page ################################################################################### ################################################################################### // status active data if(array_key_exists("status_active_lead_inquiry",$_REQUEST)){ $net_id = $_GET['id']; $query="UPDATE `lead_inquiry` SET `status` = 'active' WHERE `lead_inquiry`.`id` = '$net_id'"; if (mysqli_query($conn, $query)) { header("location:". $admin_baseurl . 'lead-inquiry.php'); } else { include('include/error-modal.php'); } mysqli_close($conn); } ########################################################################################## // status deactive data if(array_key_exists("status_deactive_lead_inquiry",$_REQUEST)){ $net_id = $_GET['id']; $query="UPDATE `lead_inquiry` SET `status` = 'deactive' WHERE `lead_inquiry`.`id` = '$net_id'"; if (mysqli_query($conn, $query)) { header("location:". $admin_baseurl . 'lead-inquiry.php'); } else { include('include/error-modal.php'); } mysqli_close($conn); } ################################################################################################## //For detete data if(array_key_exists("delete_lead_inquiry",$_REQUEST)){ $t_id = $_GET['id']; // echo $t_id; die; $query="DELETE FROM `lead_inquiry` WHERE `lead_inquiry`.`id` = '$t_id'"; if (mysqli_query($conn, $query)) { header("location:". $admin_baseurl . 'lead-inquiry.php'); } else { include('include/error-modal.php'); } mysqli_close($conn); } ################################################################################### //ContactUs inquiry page ################################################################################### // status active data if(array_key_exists("status_active_conatctUsPage_inquiry",$_REQUEST)){ $net_id = $_GET['id']; $query="UPDATE `contactUsPageEnquiry` SET `status` = 'active' WHERE `contactUsPageEnquiry`.`id` = '$net_id'"; if (mysqli_query($conn, $query)) { header("location:". $admin_baseurl . 'contactus-inquiry.php'); } else { include('include/error-modal.php'); } mysqli_close($conn); } ########################################################################################## // status deactive data if(array_key_exists("status_deactive_conatctUsPage_inquiry",$_REQUEST)){ $net_id = $_GET['id']; $query="UPDATE `contactUsPageEnquiry` SET `status` = 'deactive' WHERE `contactUsPageEnquiry`.`id` = '$net_id'"; if (mysqli_query($conn, $query)) { header("location:". $admin_baseurl . 'contactus-inquiry.php'); } else { include('include/error-modal.php'); } mysqli_close($conn); } ################################################################################################## //For detete data if(array_key_exists("delete_conatctUsPage_inquiry",$_REQUEST)){ $t_id = $_GET['id']; // echo $t_id; die; $query="DELETE FROM `contactUsPageEnquiry` WHERE `contactUsPageEnquiry`.`id` = '$t_id'"; if (mysqli_query($conn, $query)) { header("location:". $admin_baseurl . 'contactus-inquiry.php'); } else { include('include/error-modal.php'); } mysqli_close($conn); } ?>