I have a calendar table that dislays day numbers and event titles...What I want is, when the user clicks on the $aa[] event title, I want that events info to be displayed on the same page as the calendar page, near or below the calendar somewhere...So the user should stay on that page, after clicking the event title on the calendar. And event info should change and reflect his selection. Then if he clicks on another event, it should update again, etc...
Here is the part of the code, the table cell that displays calendar cells, $day_num is the day number and $aa elements are the event titles brought up from the database which satisfies users selection criteria for that day (if there is any)...
for($i=0; $i<=2; $i++){
$query = mysql_query("SELECT * FROM events_usa WHERE `sdate` = '{$daydisplay}' {$category_query} {$state_query} ORDER BY id DESC LIMIT $i,1");
while ($row = mysql_fetch_array($query)) {
$aa[$i]=$row['title'];
}}
echo "<td width=100> $day_num</br>
$aa[0]</br>
$aa[1]</br>
$aa[2]
</td>";
So what I want is, those $aa[$i], which display as title texts in table cells right now, to be links to their event rows in the database, which I want to display on the same page when user clicks on $aa[]...