MySql fetch data error - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5) +--- Forum: General Help (https://forum.codeigniter.com/forumdisplay.php?fid=24) +--- Thread: MySql fetch data error (/showthread.php?tid=82121) |
MySql fetch data error - macharia - 06-14-2022 Hey guys ! Got a problem right now, I can't fetch data from my model, operation results to an error : Call to a member function findAll() on bool the Error is: Fatal error: Uncaught Error: Call to a member function findAll() on bool in C:\Xampp1\htdocs\system\private\controllers\Home.php:13 Stack trace: #0 C:\Xampp1\htdocs\system\private\core\app.php(37): Home->index() #1 C:\Xampp1\htdocs\system\public\index.php(5): App->__construct() #2 {main} thrown in C:\Xampp1\htdocs\system\private\controllers\Home.php on line 13 Here is the code: PHP Code: for the home.php PHP Code: <?php PHP Code: <?php i am using sublime as my editor what might be the problem RE: MySql fetch data error - InsiteFX - 06-14-2022 Your showing CodeIgniter 3 codfe, what vewrsion of CodeIgniter are you running? CodeIgniter 3 did not have a findAll Method. RE: MySql fetch data error - macharia - 06-15-2022 (06-14-2022, 11:13 PM)InsiteFX Wrote: Your showing CodeIgniter 3 codfe, what vewrsion of CodeIgniter are you running? Hello . I am using sublime as my code editor and am running the system on my local host RE: MySql fetch data error - macharia - 06-15-2022 i figured it out. the problem was in my main controller. Thank you. |