Welcome Guest, Not a member yet? Register   Sign In
Cannot find model class
#11

[eluser]Karman de Lange[/eluser]
Model name = Actual file name (site_model.php) as well as the name in the calling function $this->load->model('site_model').

L:

#12

[eluser]Apidcloud[/eluser]
I've tried both approaches but it's still not working... :/
#13

[eluser]Karman de Lange[/eluser]
Ok, try following:

go to file: system/core/loader.php

Line ~298 above require_once($mod_path.'models/'.$path.$model.'.php'); add:

Code:
echo $mod_path.'models/'.$path.$model.'.php';die;


This will then print the full path to your model. Can you then please post it here or drop me PM if you don't want it on public forum
#14

[eluser]Apidcloud[/eluser]
Hey Karman, sorry for replying so late

that echo printed the following, which seems correct:
Code:
application/models/site_model.php

I've got that file inside models folder, so I have no idea why it keeps throwing that error

Thanks again
#15

[eluser]InsiteFX[/eluser]
Remove the space!

Code:
<? php

// should be

<?php
#16

[eluser]Apidcloud[/eluser]
[quote author="InsiteFX" date="1397306258"]Remove the space!

Code:
<? php

// should be

<?php
[/quote]

Indeed, that was the problem >.<

Thanks for the help!




Theme © iAndrew 2016 - Forum software by © MyBB