= $requiredrole)||(1==1)){ if ($delete=="yes"){ $result=mysql_query("delete from thread where thread_id = '$reqid'"); $delete=""; } $query2 = "select * from coaches where coach_id = '$thread_user_id'"; $result2=mysql_query($query2,$connection); $myrow2=mysql_fetch_array($result2); $thread_user_fname=$myrow2["fname"]; $thread_user_lname=$myrow2["lname"]; $thread_user_email=$myrow2["email"]; ?>

Start a new forum.

"; } echo"
Subject Title Posts Submitted by Date
$threadtype_name$thread_title$numRows$thread_user_fname $thread_user_lname$thread_date

"; // Figure out the total number of results in DB: $total_results = mysql_result(mysql_query("SELECT COUNT(*) as Num FROM thread"),0); // Figure out the total number of pages. Always round up using ceil() $total_pages = ceil($total_results / $max_results); if($total_pages >= 2){ // Build Previous Link if($page > 1){ $prev = ($page - 1); echo "Previous | "; } for($i = 1; $i <= $total_pages; $i++){ if(($page) == $i){ echo "$i | "; } else { echo "$i | "; } } // Build Next Link if($page < $total_pages){ $next = ($page + 1); echo "Next"; } } echo "
"; ?>
$no_access

"?>