//number of pages to display. number - 1. ex: for 5 value should be 4 $page_limit = 6; //Load required class files. post.class and cache.class $post = new post(); $cache = new cache(); header("Cache-Control: store, cache"); header("Pragma: cache"); $domain = $cache->select_domain(); $id = $db->real_escape_string($_GET['id']); if (!is_numeric($id)) { $id = str_replace("#", "", $id); } $id = (int) $id; $date = date("Ymd"); //Load post_table data and the previous next values in array. 0 previous, 1 next. $post_data = $post->show($id); //Check if data exists in array, if so, kinda ignore it. if ($post_data == "" || is_null($post_data)) { header('Location: index.php?page=post&s=list'); exit; } $prev_next = $post->prev_next($id); if (!is_dir("{$main_cache_dir}" . "" . "\\cache/{$id}")) { $cache->create_page_cache("cache/{$id}"); } $data = $cache->load("cache/" . $id . "/post.cache"); if ($data !== false) { echo str_replace("f6ca1c7d5d00a2a3fb4ea2f7edfa0f96a6d09c11717f39facabad2d724f16fbb", $domain, $data); flush(); $tcount = 1; } else {