Call to undefined method my_model:dame_articulos() |
[eluser]lucasvm[/eluser]
Hello Im getting this error when i try to acces to the article page on my website, im doing this: Code: function muestra($id){ So the model articulos_model dooes exists, also the function dame_articulo existis and im doing this in articulos_model: Code: function dame_articulos($id){ Does anybody knows why im getting this error? and how can i fix it?
[eluser]InsiteFX[/eluser]
Try this, also make sure that you saved your model with all lowercase name! You should also read the CodeIgniter User Guide - General Style and Syntax. Code: function muestra($id){ InsiteFX
[eluser]lucasvm[/eluser]
im getting the same error... i dont know why, the name is the same as the function...
[eluser]TWP Marketing[/eluser]
@InsiteFX The model name needs to be Capitalized in almost all usage. It's the file name that is lowercase. @lucasvm. Your controller function looks ok. As Insitefx said, check the filename itself, it should be lower case. Code: ...
[eluser]lucasvm[/eluser]
Thank you, the file name calls articulos_model.php located in models folder. I dont know what to do
[eluser]InsiteFX[/eluser]
@TWP Wrong! If you read the code in the loader of the model you will see that it uppercases the model name. Code: $model = strtolower($model); InsiteFX
|
Welcome Guest, Not a member yet? Register Sign In |