CodeIgniter Forums

Full Version: Extending Model not working on OVH Web hosting
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

El Forum

[eluser]Unknown[/eluser]
hi all !

I have a problem with a simple librairy in CodeIgniter 2.1.3.

This librairy : https://github.com/jesseterry/CodeIgniter-CRUD-Model

When i use this librairy in local with wamp (php 5.3.10), it works perfectly.

but I want to use this librairy on a project hosted in OVH web hosting (French) and it return a error like this :

Fatal error: Class 'MY_Model' not found in /homez.xxx/hosting/mobile/application/models/images_model.php on line 4

I have copy the My_Model.php in my ./application/core folder

I have create a model who extends My_Model in my ./application/models folder (images_models) like this :

Code:
<?php  if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class images_model extends MY_Model
{
public $table = 'images';
public $primary_key = "images.id";

    public function default_join()
    {

        $this->db->join('artistes', 'artistes.id = images.id');  
        $this->db->join('type_image', 'type_image.id_type = images.type');    
    }


}
?>

In my controller i have include my model :

$this->load->model('images_model','imagesManager');

And i don't understand why on OVh Web hosting it not work !!!

If you have an idea because I tear my hair Undecided

Thanks. (sorry for my english, i French)

Laurent

El Forum

[eluser]InsiteFX[/eluser]
Make sure that when you upload all your files that you save them as lowercase filenames, a lot ISP's use case sentitivity.

El Forum

[eluser]Unknown[/eluser]
Thank you for your reply.

The problem it's the name of my file "MY_Model.php" in the core folder.

I rename it "My_Model.php and it's ok ! :-)