Newbie at Codeigniter with Login Model - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: Newbie at Codeigniter with Login Model (/showthread.php?tid=43838) |
Newbie at Codeigniter with Login Model - El Forum - 07-25-2011 [eluser]Unknown[/eluser] Hi , every one , well , this is first time i use a framework , Friends recommanded me CodeIgniter , that i found very usefull ! well i have problem with the mysql_nu_rows i didn't find an equivalent in Db librairy please help me solving this problem , i need to uses it here Code: <?php i have always 0 as value of return wich means count_all is null of course with correct login name and pass Newbie at Codeigniter with Login Model - El Forum - 07-25-2011 [eluser]Benito[/eluser] Welcome to the Forums! The reason for your problem is that you are not returning the results. What you should be using is: Code: if($query->num_rows() == 1) You should check the documentation for generating query results. Cheers. |