Page 1 of 1

display one question per page

Posted: Mon Apr 30, 2007 1:58 am
by qumar
hi everybody,
i am doing the project on online exam.
in admin side, i created tests. each test has 5 questions.
i have created questions and choices. inserted into database.i finished the admin part. problem is userside.
in user side, one question should display per page and
press next button to go next page. at the end all
questions result should display.
please help me how can i do in user side.
and also gvie the sample website.

thanks,
qumar.

Posted: Mon Apr 30, 2007 2:16 am
by mentor
You can use limit in MySQL query e.g.

Code: Select all

SELECT * FROM questions LIMIT 0,1
on next page

Code: Select all

SELECT * FROM questions LIMIT 1,1
and then

Code: Select all

SELECT * FROM questions LIMIT 2,1

Posted: Mon Apr 30, 2007 5:00 pm
by RobertGonzalez
Search for 'pagination'. There are lots of posts for this around here.