Forum Moderators: coopster
I'm using data from a MySQL table, with a varying amount of keys.
I would like to have a maximum of three expressions showing, but if there are less than three, say two, I only want to run the function two times.
Right now, I have the following statement, which works fine if there are up to three keys in the table, but right now, it will just keep on running all the way up to the total amount of keys.
for($i=0;$i<count($keys);$i++){...}
Is there a way I can set a max at three?
Thanks