rendered paste body<div id="main"><div id="maincontent"><?phpinclude("db.php");//Pagination for Blog$page = $_GET['id'];if(!isset($page)) $page = 1;$max_results = 2;$from = (($page * $max_results) - $max_results);function paging($max_results, $page){$total_results = mysql_result(mysql_query("SELECT COUNT(*) AS ID FROM `posts`"),0);$total_pages = ceil($total_results / $max_results);if($total_pages > 1){echo "<div align='center'><br/>\n";if($page > 1){$prev = ($page - 1);//link backecho "<a href=\"?p=home&id=$prev\"><< </a> \n";}if($page < $total_pages){$next = ($page + 1);//link to moreecho "<a href=\"?p=home&id=$next\"> >></a>\n";}echo " </b></div>\n";}}$result = mysql_query("SELECT * FROM `posts` ORDER BY `ID` DESC LIMIT $from, $max_results");while($row = mysql_fetch_assoc($result)){?><h3><a href="?p=post&id=<?php echo $row["ID"]; ?>"><?php echo $row["title"]; ?></a> - <?php echo $row['date']; ?></h3><p><?php$string = $row['content'];$length = strlen($string);$new_string = substr($string, 0, 360);$new_length = strlen($new_string);$id = $row['ID'];if($new_length < $length){echo "$new_string ... <a href='?p=post&id=$id'><code><more></code></a>";} else {echo $string; }?></p><?php } ?><?php paging($max_results, $page) ?></div> <!-- end main content section -->