countvotes - 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: countvotes (/showthread.php?tid=22347) |
countvotes - El Forum - 09-06-2009 [eluser]benfike[/eluser] Hi! How can I count the answer for the votes_answers? votes_votes table structure: id ansid - answer id voteid - the poll id userid - userid Code: function countVotesByAnsId($id){ Now only count the first Answer, answers. countvotes - El Forum - 09-06-2009 [eluser]benfike[/eluser] the rsult view: Code: <?php foreach($answers as $answer):?> here is the $szavazat = that function |