CQuestions
CQid, CQText
CAnswers
Aaid, AaText, CQid, CQAns
CResults
Rid, Email, Marks
i want to display questions and multiple answers from database. this code will display all the questions from the database. i want to display only 3 questions daily. every day new set of question should be displayed… how to do it?
There are 100 questions in DB. but i want to display only the 3 questions everyday… for example,
[sup]1st day cqid=1, cqid=2, cqid=3 should display.
2nd day cqid=4, cqid=5, cqid=6
2nd day cqid=7, cqid=8, cqid=9 like wise…[/sup]
the questions must change automatically everyday…
This is the form. test.php
[code]<?php
include(“config.php”);
session_start();
include(“lock.php”);
?>
" . $row['cqtext'] . "
"; $sql2="SELECT * FROM canswers where cqid=".$row['cqid']; $result2=mysql_query($sql2); while($row2=mysql_fetch_assoc($result2)){ echo "".$row2['aatext']; } /*echo "";*/ } echo""; echo ""; ?>[/code]