detail); //print("$detail"); print("
"); echo format_post($pid); print ("
"); break; default: $limit=10; if (empty($page)) { $page=1; } $limitvalue = $page * $limit - ($limit); $q = mysql_query("select a.post_num, a.title, b.stardate, b.time from posts_index a, ships_logs2 b where b.ship = '$ship_num' and a.post_num = b.idx and a.char_id = '$id' order by b.stardate, b.time"); $q1 = mysql_query("select a.post_num, a.title, b.stardate, b.time from posts_index a, ships_logs2 b where b.ship='$ship_num' and a.post_num = b.idx and a.char_id = '$id' order by b.stardate, b.time LIMIT $limitvalue, $limit"); $totalrows = mysql_num_rows($q); $q2 = mysql_query("select * from bios where ID = '$id'"); $pic = mysql_fetch_object($q2); print("
image> Post Archive
"); if ($totalrows == 0) { print("There is nothing to display
"); } while($row=mysql_fetch_object($q1)) { print("post_num&mode=display>$row->title
"); } print("
"); if ($totalrows > $limit ) { print("
"); if($page != 1){ $pageprev = $page - 1; print("<< "); }else print(" "); $numofpages = $totalrows / $limit; for($i = 1; $i <= $numofpages; $i++){ if($i == $page){ print($i." "); }else{ print("$i "); } } if(($totalrows % $limit) != 0){ if($i == $page){ print($i." "); }else{ print("$i "); } } // Ends the if statement if(($totalrows - ($limit * $page)) > 0){ $pagenext = $page+ 1; print(">>"); }else{ print(""); print(""); } } } print("
"); include("foot.php");