I Can't include file from config in model page

#1
[eluser]Mr.CodeIgniter[/eluser]
I don't know why, but i try

sorry , i am from saudi arabia
Code:
<?php
class functions extends Model {
    function Pages($url)
    {
        //test
    }
    function Defaults()
    {
        $data['url_view']=base_url()."system/application/views/";
        $data['url_controller']=base_url()."system/application/controller/";
        $data['url_config']=base_url()."system/application/config/";
        $data['MainMenu']=$this->db->get('page');
        $url=$data['url_config'].'MyConfig.php';
        include($url);
        $data['config']=$Config;
        return $data;
    }
}
?>
this is model file

#2
[eluser]InsiteFX[/eluser]
This does not tell us much!

What file are you trying to include?

Show your model code and please use code tags.

InsiteFX

#3
[eluser]cchi[/eluser]
are you trying to make it modular??

#4
[eluser]InsiteFX[/eluser]
Code:
class functions extends Model {

function functions()
    {
        // Call the Model constructor
        parent::Model();
    }
    
}

// in your controller or where you are calling it from

$this->load->model('functions');

InsiteFX


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.