Server IP : 80.241.246.6 / Your IP : 216.73.216.188 Web Server : Apache/2.4.25 (Debian) System : Linux kharagauli 4.9.0-19-amd64 #1 SMP Debian 4.9.320-2 (2022-06-30) x86_64 User : www-data ( 33) PHP Version : 7.0.33-0+deb9u12 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority, MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /var/www/kharagauli_new/moduls/big_logo/admin/ |
Upload File : |
<?php /* @author suxoza <suxoza@gmail.com> */ if(realpath(__FILE__) == realpath($_SERVER['SCRIPT_FILENAME']))die("__main__"); $_time = time(); if($_POST['time']){ list($day,$month,$year) = explode('/',$_->clier($_POST['time'])); $_time = mktime(date("H"), date("i"), 0, $month, $day, $year); } $_logo = ''; if(!isset($url[4]) && in_array('more', $url))throw new Exception("bad uri format!!!"); $_logo = $_POST['logo']; $slide_1 = (isset($_POST['setting_slide_1']) && $_POST['setting_slide_1'])?1:0; $insert = ['logo','attributes','banner','slide_1','page_date','date_modify']; $value = [$_logo,'',$_POST['banner'],$slide_1,$_time,time()]; for($i = 0; $i < count($_->language_config); $i++){ $insert[] = "name_".$_->language_config[$i]; $insert[] = "body_".$_->language_config[$i]; $value[] = $_->clier($_POST['name_'.$_->language_config[$i]]); $bd = addslashes($_POST['body_'.$_->language_config[$i]]); // if($select_body) // _files::custom_delete_images_from_body($select_body['body_'.$_->language_config[$i]],$bd); $value[] = $bd; } $navig_name = '/'.$url[1].'/'.$url[2]; try{ if(in_array('more', $url)){ if(!$_->permission_($select_menu['id'],'edit')) throw new Exception("Error Processing Request", 1); if($_->update("body",[$insert,$value,["id",$url[4]]],0)){ insert_relation_($_,$url[4],true); header("Location:".location($_POST['added_params'],$navig_name,$_).$_COOKIE['location_href_menu']."/changed/"); }else die("update error!!!!!"); }elseif(in_array('new', $url)){ if(!$_->permission_($select_menu['id'],'add')) throw new Exception("Error Processing Request", 1); $insert[] = "date"; $value[] = time(); $ID = $_->insert("body",[$insert,$value],'b_clier'); insert_relation_($_,$ID); if($ID) header("Location:".location($_POST['added_params'],$navig_name,$_,$ID).$_COOKIE['location_href_menu']."/added/"); else die("insert error!!!!!"); }else die("unconv uri!!!"); }catch(Exception $exc) { die($exc->getMessage()); } function insert_relation_($_,$ID,$update = false){ if(count($_POST['categoryes'])){ if($update) $_->delete("menu_body",["body_id",$ID]); $menu_body = [ ["menu_id","body_id"], [] ]; for($i = 0; $i < count($_POST['categoryes']); $i++) $menu_body[1][] = [$_POST['categoryes'][$i],$ID]; $_->insert_array("menu_body",$menu_body); } } function location($a,$navig_name,$_,$ID){ if(!$a)return $_SERVER['HTTP_REFERER']; elseif($a == 1)return $navig_name; elseif($a == 2)return $navig_name.'/more/'.$ID; } ?>