Page 1 of 1

Playing with Listbox

Posted: Sun Oct 21, 2007 2:02 pm
by ashrafzia
I have got all my programe_names from my table inside a list box.
Now i want whenever a progame_name is selected, the no of semesters for a programe which we are also retrieving from the table, let us say for the programe BBA the no of semesters are 8 which is stored inside a table. I want to show all the semester no's from 1,2,3.....8 inside the semester list box.
How can i put this logic???
and remember whenever a different programe_name is selected, the no of semesters stored for it in the table should be retrieved and then a loop will be started from 1....upto that No which is retrieved and then those values will be printed inside the listbox.

I want to apply all this logic on runtime. Any idea!

THanx in Advance.

Posted: Mon Oct 22, 2007 4:59 pm
by feyd
A for loop would probably do what you wish.

http://php.net/for