echo str_replace('\\', "\", str_replace(' ', '%20', str_replace("'", "'", $row['user']))); ?> '} //]]> </script> <?php if ($got_permission !== false) { ob_flush(); flush(); } ++$ccount; } echo "<br /><br /><div id='paginator'>"; //Functionized the paginator... Let's see how well this works in practice. $misc = new misc(); print $misc->pagination($_GET['page'], $_GET['s'], $id, $limit, $page_limit, $count, $pid); echo '<script type="text/javascript"> //<![CDATA[ filterComments(\'' . $id . '\', \'' . $ccount . '\') //]]></script></div><a href="#" onclick="Javascript:showHide(\'comment_form\'); return false;">>>Respond</a> <form method="post" action="index.php?page=comment&id=' . $id . '&s=save" name="comment_form" id="comment_form" style="display:none"> <table><tr><td> <textarea name="comment" rows="0" cols="0"></textarea> </td></tr><tr><td>Post as anonymous?<br /> <input type="checkbox" name="post_anonymous"/> </td></tr><tr><td> <input type="submit" name="submit" value="Post comment"/> </td></tr><tr><td> <input type="hidden" name="conf" id="conf" value="0"/> </td></tr></table></form> <script type="text/javascript">
} $query = "SELECT COUNT(*) FROM {$alias_table} WHERE status !='rejected'"; $result = $db->query($query); $row = $result->fetch_assoc(); $count = $row['COUNT(*)']; $numrows = $count; $result->free_result(); $query = "SELECT * FROM {$alias_table} WHERE status != 'rejected' ORDER BY alias ASC LIMIT {$page}, {$limit}"; $result = $db->query($query) or die($db->error); $ccount = 0; print '<table class="highlightable" style="width: 100%;"><tr><th width="25%"><b>Tag:<small> (What you search for...)</small></b></th><th width="25%"><b>Alias:</b><small> (What it should be...)</small></th><th>Reason:</th></tr>'; while ($row = $result->fetch_assoc()) { if ($row['status'] == "pending") { $status = "pending-tag"; } else { $status = ""; } echo '<tr class="' . $status . '"><td>' . $row['alias'] . '</td><td>' . $row['tag'] . '</td><td>' . $row['reason'] . '</td></tr>'; } echo '</table><br /><br /> <form method="post" action=""><table><tr><td> <b>Name:</b></td><td><input type="text" name="alias" value=""/></td></tr> <tr><td><b>Alias to:</b></td><td><input type="text" name="tag" value=""/></td></tr> </table> <input type="submit" name="submit" value="Submit"/> </form> <div id="paginator">'; $misc = new misc(); print $misc->pagination($_GET['page'], $sub, $id, $limit, $page_limit, $numrows, $_GET['pid'], $tags); ?> </div></div></body></html>
$t_decode = urlencode(html_entity_decode($ttags, ENT_NOQUOTES, "UTF-8")); $c_decode = urlencode(html_entity_decode($current, ENT_NOQUOTES, "UTF-8")); echo '<li><a href="index.php?page=post&s=list&tags=' . $t_decode . "+" . $c_decode . '">+</a><a href="index.php?page=post&s=list&tags=' . $t_decode . "+-" . $c_decode . '">-</a> <span style="color: #a0a0a0;">? <a href="index.php?page=post&s=list&tags=' . $c_decode . '">' . str_replace('_', ' ', $current) . '</a> ' . $row['index_count'] . '</span></li>'; } //Print out image results and filter javascript echo '<li><br /><br /></li></ul></div></center></div></div><div class="content"><div>'; $images .= "</div><br /><br /><div id='paginator'>"; $images .= '<script type="text/javascript"> //<![CDATA[ filterPosts(posts) //]]> </script>'; echo $images; //Pagination function. This should work for the whole site... Maybe. $misc = new misc(); print $misc->pagination($_GET['page'], $_GET['s'], $id, $limit, $page_limit, $numrows, $_GET['pid'], $_GET['tags']); } //Cache doesn't exist for search, make one. if ($no_cache === true) { $data = ob_get_contents(); ob_end_clean(); if (isset($_GET['pid']) && is_numeric($_GET['pid']) && $_GET['pid'] > 0) { $page = $_GET['pid'] / $limit + 1; } else { $page = 0; } if ($new_tag_cache != "") { if (!is_dir("{$main_cache_dir}" . "" . "search_cache/" . $new_tag_cache)) { @mkdir("{$main_cache_dir}" . "" . "search_cache/" . $new_tag_cache); } $cache->save("search_cache/" . $new_tag_cache . "/" . $page . ".html", $data);
$images .= '<span class="thumb" style="margin: 10px;"><a href="index.php?page=post&s=view&id=' . $row['id'] . '" id="p' . $row['id'] . '" onclick="document.location=\'index.php?page=post&s=view&id=' . $row['id'] . '\'; return false;"><img src="' . $thumbnail_url . $misc->getThumb($row['image'], $row['directory']) . '" title="' . $tags . '" border="0" alt="image_thumb"/></a>'; isset($_COOKIE['user_id']) && $_COOKIE['user_id'] == $id ? $images .= '<br /><a href="#" onclick="document.location=\'index.php?page=favorites&s=delete&id=' . $row['id'] . '&pid=' . $page . '\'; return false;"><b>Remove</b></a></span>' : ($images .= '</span>'); $images .= '<script type="text/javascript"> posts[' . $row['id'] . '] = {\'tags\':\'' . str_replace('\\', "\", str_replace(' ', '%20', str_replace("'", "'", $tags))) . '\'.split(/ /g), \'rating\':\'' . $row['rating'] . '\', \'score\':' . $row['score'] . ', \'user\':\'' . str_replace('\\', "\", str_replace(' ', '%20', str_replace("'", "'", $row['owner']))) . '\'} </script>'; } $images .= '<div style="margin-top: 550px; text-align: right;"><a id="pi" href="#" onclick="showHideIgnored(\'0\',\'pi\'); return false;"></a></div> <script type="text/javascript"> filterPosts(posts) </script> <div id=\'paginator\'>'; echo $images; ob_flush(); flush(); $result->free_result(); print $misc->pagination($_GET['page'], $_GET['s'], $id, $limit, $page_limit, $numrows, $page); } else { if (isset($_GET['s']) && $_GET['s'] == "list") { //List how many users per page that should be here. //number of images/page $limit = 50; //number of pages to display. number - 1. ex: for 5 value should be 4 $page_limit = 6; header("Cache-Control: store, cache"); header("Pragma: cache"); require "includes/header.php"; echo '<div id="content"><div id="account-favorites-list"><table width="100%"><tr><th width="30%">User</th><th width="70%">Count</th></tr>'; if (isset($_GET['pid']) && $_GET['pid'] != "" && is_numeric($_GET['pid']) && $_GET['pid'] >= 0) { $page = $db->real_escape_string($_GET['pid']); } else { $page = 0;