本文整理汇总了PHP中Pagination::next_page方法的典型用法代码示例。如果您正苦于以下问题:PHP Pagination::next_page方法的具体用法?PHP Pagination::next_page怎么用?PHP Pagination::next_page使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Pagination
的用法示例。
在下文中一共展示了Pagination::next_page方法的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: Pagination
$session->message("<div class='success'>Job(s) has been remove from Spotlight</div>");
redirect_to($_SERVER['PHP_SELF']);
die;
}
}
$page = !empty($_GET['page']) ? (int) $_GET['page'] : 1;
$per_page = JOBS_PER_SEARCH;
$total_count = Job::count_all();
$smarty->assign('total_count', $total_count);
$smarty->assign('page', $page);
$pagination = new Pagination($page, $per_page, $total_count);
$smarty->assign('previous_page', $pagination->previous_page());
$smarty->assign('has_previous_page', $pagination->has_previous_page());
$smarty->assign('total_pages', $pagination->total_pages());
$smarty->assign('has_next_page', $pagination->has_next_page());
$smarty->assign('next_page', $pagination->next_page());
$offset = $pagination->offset();
$sql = " SELECT * FROM " . TBL_JOB;
$sql .= " LIMIT {$per_page} ";
$sql .= " OFFSET {$offset} ";
$lists = Job::find_by_sql($sql);
$manage_lists = array();
if ($lists && is_array($lists)) {
$i = 1;
foreach ($lists as $list) {
unset($employer);
if (!empty($list->fk_employer_id) && $list->fk_employer_id != 0) {
$employer = Employer::find_by_id($list->fk_employer_id);
}
$manage_lists[$i]['id'] = $list->id;
$manage_lists[$i]['job_title'] = $list->job_title;
示例2:
$serial_no++;
}
}
?>
</table>
<div class="pagination " style="clear: both;">
<ul>
<?php
if ($pagination->total_pages() > 1) {
if ($pagination->has_previous_page()) {
echo "<li class='disabled'><a href=\"cheack_my_feedbacks.php?page=";
echo $pagination->previous_page();
echo "\">« Previous</a></li> ";
}
for ($i = 1; $i <= $pagination->total_pages(); $i++) {
if ($i == $page) {
echo "<li><span class=\"selected\">{$i}</span></li>";
} else {
echo "<li><a href=\"cheack_my_feedbacks.php?page={$i}\">{$i}</a></li>";
}
}
if ($pagination->has_next_page()) {
echo "<li class='disabled'> <a href=\"cheack_my_feedbacks.php?page=";
echo $pagination->next_page();
echo "\">Next »</a></li> ";
}
}
?>
</ul>
</div>
示例3: confirm
</td>
<?php
if ($_SESSION['role'] != "moderator" && $_SESSION['role'] != "student") {
echo "<td><a href=\"edit_request.php?id={$request->id}\"><i class=\"small circular inverted orange edit icon\"></i></a></td>\t\n\t\t\t<td><a href=\"delete_request.php?id={$request->id}\" onclick=\"return confirm('Are you sure?');\"><i class=\"small circular inverted red remove icon\"></i></a></td>\n\t\t\t\n\t\t\t";
}
?>
</tr>
<?php
}
?>
</table>
<?php
$prev = $pagination->previous_page();
$next = $pagination->next_page();
$lastpage = $pagination->total_pages();
$LastPagem1 = $lastpage - 1;
$paginate = '';
if ($lastpage > 1) {
$paginate .= "<ul class='pagination'>";
// Previous
if ($pagination->has_previous_page()) {
$paginate .= "<li><a href='list_requests.php?page={$prev}'>« Previous</a></li>";
}
// Pages
if ($lastpage < 7 + $stages * 2) {
for ($counter = 1; $counter <= $lastpage; $counter++) {
if ($counter == $page) {
$paginate .= "<li class='active'><a href='list_requests.php?page={$counter}'>{$counter}</a></li>";
} else {
示例4:
?>
</table> -->
<div id="pagination" style="clear:both;">
<?php
if ($pagination->total_pages() > 1) {
if ($pagination->has_prev_page()) {
echo " <a href=\"index.php?page=" . $pagination->previous_page() . "\">previous «</a>";
}
for ($i = 1; $i <= $pagination->total_pages(); $i++) {
if ($i == $page) {
echo "<span class=\"selected\" >" . $i . "</span>";
} else {
echo "<a href=\"index.php?page=" . $i . "\">" . $i . "</a>";
}
}
if ($pagination->has_next_page()) {
echo " <a href=\"index.php?page=" . $pagination->next_page() . "\">Next »</a>";
}
}
?>
<br />
<br />
<hr />
<a href="admin/login.php">» Upload A New Photograph</a>
<hr />
<a href="index.php">« Back</a>
</div>
<?php
include_layout_template("admin_footer.php");
示例5:
<ul class="pagination">
<?php
if ($pagination->has_previous_page()) {
echo "<li><a href=\"add_town.php?page={$pagination->previous_page()}\">«</a></li>";
} else {
echo "<li class=\"disabled\"><span>«</span></li>";
}
for ($i = 1; $i <= $pagination->total_page(); $i++) {
if ($i == $pagination->current_page) {
echo "<li class=\"active\"><a href=\"add_town.php?page={$i}\">{$i}</a></li>";
} else {
echo "<li><a href=\"add_town.php?page={$i}\">{$i}</a></li>";
}
}
if ($pagination->has_next_page()) {
echo "<li><a href=\"add_town.php?page={$pagination->next_page()}\">»</a></li>";
} else {
echo "<li class=\"disabled\"><span>»</span></li>";
}
?>
</ul>
<?php
}
?>
</div>
</div>
<!--END OF PAGINATION CLICK-->
示例6: urldecode
</div>
<?php
}
?>
<div id="pagination" style="clear: both;">
<?php
if ($pagination->total_pages() > 1) {
if ($pagination->has_previous_page()) {
echo "<a href=\"index.php?page=";
echo urldecode($pagination->previous_page());
echo "\">« Previous</a> ";
}
for ($i = 1; $i <= $pagination->total_pages(); $i++) {
if ($i == $page) {
echo " <span class=\"selected\">{$i}</span> ";
} else {
echo " <a href=\"index.php?page={$i}\">{$i}</a> ";
}
}
if ($pagination->has_next_page()) {
echo " <a href=\"index.php?page=";
echo urldecode($pagination->next_page());
echo "\">Next »</a> ";
}
}
?>
</div>
<?php
include SITE_ROOT . DS . 'public' . DS . 'layouts' . DS . "footer_2.php";
示例7:
<ul class="pagination">
<?php
if ($pagination->has_previous_page()) {
echo "<li><a href=\"Team_member.php?page={$pagination->previous_page()}\">«</a></li>";
} else {
echo "<li class=\"disabled\"><span>«</span></li>";
}
for ($i = 1; $i <= $pagination->total_page(); $i++) {
if ($i == $pagination->current_page) {
echo "<li class=\"active\"><a href=\"Team_member.php?page={$i}\">{$i}</a></li>";
} else {
echo "<li><a href=\"Team_member.php?page={$i}\">{$i}</a></li>";
}
}
if ($pagination->has_next_page()) {
echo "<li><a href=\"Team_member.php?page={$pagination->next_page()}\">»</a></li>";
} else {
echo "<li class=\"disabled\"><span>»</span></li>";
}
?>
</ul>
<?php
}
?>
</div>
</div>
<!--END OF PAGINATION CLICK-->
</div>
<div class="col-sm-4"style="padding-top:34px;">
示例8:
<ul class="pagination">
<?php
if ($pagination->has_previous_page()) {
echo "<li><a href=\"Event_5.php?page={$pagination->previous_page()}\">«</a></li>";
} else {
echo "<li class=\"disabled\"><span>«</span></li>";
}
for ($i = 1; $i <= $pagination->total_page(); $i++) {
if ($i == $pagination->current_page) {
echo "<li class=\"active\"><a href=\"Event_5.php?page={$i}\">{$i}</a></li>";
} else {
echo "<li><a href=\"Event_5.php?page={$i}\">{$i}</a></li>";
}
}
if ($pagination->has_next_page()) {
echo "<li><a href=\"Event_5.php?page={$pagination->next_page()}\">»</a></li>";
} else {
echo "<li class=\"disabled\"><span>»</span></li>";
}
?>
</ul>
<?php
}
?>
</div>
</div>
<!--END OF PAGINATION CLICK-->
</div>
<div class="col-xs-4" style="padding-top:34px;">
示例9:
<ul class="pagination">
<?php
if ($pagination->has_previous_page()) {
echo "<li><a href=\"customer_feedback_6.php?page={$pagination->previous_page()}\">«</a></li>";
} else {
echo "<li class=\"disabled\"><span>«</span></li>";
}
for ($i = 1; $i <= $pagination->total_page(); $i++) {
if ($i == $pagination->current_page) {
echo "<li class=\"active\"><a href=\"customer_feedback_6.php?page={$i}\">{$i}</a></li>";
} else {
echo "<li><a href=\"customer_feedback_6.php?page={$i}\">{$i}</a></li>";
}
}
if ($pagination->has_next_page()) {
echo "<li><a href=\"customer_feedback_6.php?page={$pagination->next_page()}\">»</a></li>";
} else {
echo "<li class=\"disabled\"><span>»</span></li>";
}
?>
</ul>
<?php
}
?>
</div>
</div>
<!--END OF PAGINATION CLICK-->
示例10:
<span class="selected"><?php
echo $j;
?>
</span>
<?php
} else {
?>
<a href="javascript:void(0)" onClick="call_review('review.php?page=<?php
echo $j;
?>
')"> <?php
echo $j;
?>
</a>
<?php
}
}
?>
<?php
if ($pg->has_next_page()) {
?>
<a href="javascript:void(0)" onClick="call_review('review.php?page=<?php
echo $pg->next_page();
?>
')"> Next »</a>
<?php
}
}
?>
</div>
示例11:
echo '</li>';
}
echo '</ul>';
*/
echo '<ul class="pagination pagination">';
echo $pagination->has_previous_page() ? '<li><a href="list_photos.php?page=' . $pagination->previous_page() . '">«</a></li>' : '<li class="disabled"><a href="">«</a></li>';
for ($i = 1; $i <= $pagination->total_pages(); $i++) {
echo '<li';
echo $i == $pagination->current_page ? ' class="active"' : '';
echo '>';
echo '<a href="list_photos.php?page=';
echo $i;
echo '">' . $i . '</a>';
echo '</li>';
}
echo $pagination->has_next_page() ? '<li><a href="list_photos.php?page=' . $pagination->next_page() . '">»</a></li>' : '<li class="disabled"><a href="">»</a></li>';
echo '</ul>';
}
?>
</div>
<!-- End Pagination -->
<!-- End Content -->
</div>
<div id="push"></div>
</div>
<?php
示例12: Pagination
$anotherpagination = new Pagination($page, $per_page, $total_count);
if ($anotherpagination->total_pages() > 1) {
if ($anotherpagination->has_previous_page()) {
echo "<a href =\"allusers.php?page=";
echo $anotherpagination->previous_page();
echo "\">« Previous</a> ";
}
for ($i = 1; $i <= $anotherpagination->total_pages(); $i++) {
if ($i == $page) {
echo " <span class=\"selected\">{$i}</span> ";
} else {
echo " <a href=\"allusers.php?page={$i}\">{$i}</a> ";
}
}
if ($anotherpagination->has_next_page()) {
echo " <a href =\"allusers.php?page=";
echo $anotherpagination->next_page();
echo "\">Next »</a> ";
}
}
?>
</div>
</div>
</div>
</div>
</body>
<?php
include 'footer.php';
示例13:
echo "</tr>";
}
?>
</table>
<div id="pagination">
<?php
if ($pagination->total_pages() > 1) {
if ($pagination->has_prev_page()) {
echo " <a href=\"view_photograph.php?page=" . $pagination->previous_page() . "\">previous «</a>";
}
for ($i = 1; $i <= $pagination->total_pages(); $i++) {
if ($i == $page) {
echo "<span class=\"selected\" >" . $i . "</span>";
} else {
echo "<a href=\"view_photograph.php?page=" . $i . "\">" . $i . "</a>";
}
}
if ($pagination->has_next_page()) {
echo " <a href=\"view_photograph.php?page=" . $pagination->next_page() . "\">Next »</a>";
}
}
?>
</div>
<br />
<a href="photo_upload.php">» Upload A New Photograph</a>
<hr />
<br />
<a href="index.php">« Back</a>
<?php
include_layout_template("admin_footer.php");