當前位置: 首頁>>代碼示例>>PHP>>正文


PHP pagination::showPagination方法代碼示例

本文整理匯總了PHP中pagination::showPagination方法的典型用法代碼示例。如果您正苦於以下問題:PHP pagination::showPagination方法的具體用法?PHP pagination::showPagination怎麽用?PHP pagination::showPagination使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在pagination的用法示例。


在下文中一共展示了pagination::showPagination方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: substr

        if (strlen($games['description']) > 180) {
            $games['description'] = substr($games['description'], 0, 180) . '...';
        }
        $games['description'] = stripslashes($games['description']);
        $description = str_replace(array("\r\n", "\r", "\n", "'", '"'), ' ', $games['description']);
        $pic_settings = array('w' => 130, 'h' => 100);
        echo '<div class="download">
		<ul>
		<li class="title"><div class="downloadheader">' . $games['title'] . '</div></li>
		<li class="even"><div class="container_box7"><div class="gameholderimg"><img align="absmiddle" src="' . resize($thumbpath, $pic_settings, "download") . '" alt="' . $thumbpath . '" width="130" height="100" /></div><div class="desc">' . $games['description'] . '</div>';
        if ($games['mochi'] != '') {
            echo '<div class="clear"></div><div class="downloadgame"><center><a href="' . $setting['siteurl'] . $filepath . '" onclick="return download_link(' . $games['id'] . ')"><img align="absmiddle" src="' . $setting['siteurl'] . 'templates/' . $setting['theme'] . '/skins/' . $setting['skin'] . '/images/buttons/download.png" width="100" height="30" /></a></center></div>';
            echo '<div class="downloadmochi"><center><a href="' . $games['mochi'] . '" rel="nofollow" onclick="return download_link_mochi(' . $games['id'] . ')"><img align="absmiddle" src="' . $setting['siteurl'] . 'templates/' . $setting['theme'] . '/skins/' . $setting['skin'] . '/images/buttons/downloadmochi.png" width="100" height="30" /></a></center></div>';
            echo '</div><div class="clear"></div></li></ul></div>';
        } else {
            echo '<div class="clear"></div><div class="downloadgame"><center><a href="' . $setting['siteurl'] . $filepath . '" onclick="return download_link(' . $games['id'] . ')"><img align="absmiddle" src="' . $setting['siteurl'] . 'templates/' . $setting['theme'] . '/skins/' . $setting['skin'] . '/images/buttons/download.png" width="100" height="30" /></a></center></div>';
            echo '</div><div class="clear"></div></li></ul></div>';
        }
    }
    $select_games->close();
}
?>

<div id="page_box">
<?php 
echo $pageurl->showPagination();
?>

</div>	
<div class="clear"></div>
</div>
開發者ID:royalswe,項目名稱:yas26,代碼行數:31,代碼來源:download.php

示例2: extract

}
$table = "siswa";
foreach ($conn->getTableData($table, $page, $dataPerPage) as $value) {
    extract($value);
    echo "\n\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t<td>{$nis}</td>\n\t\t\t\t\t\t\t<td>{$nama}</td>\n\t\t\t\t\t\t\t<td>{$kelas}</td>\n\t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t";
}
?>
		</tbody>
		<tfoot>
		    <tr>
		    	<th colspan="3">
			      	<div class="ui right floated pagination menu">
				        <a class="icon item">
				          	<i class="left chevron icon"></i>
				     	</a>
					      <?php 
$conn->showPagination($table, $dataPerPage);
?>
				        <a class="icon item">
				         	<i class="right chevron icon"></i>
			        	</a>
		      		</div>
		    	</th>
		  	</tr>
		</tfoot>
	</table>
</div>
</div>

</body>
</html>
開發者ID:RiskyFeryansyah,項目名稱:Pagination_PHPPDO,代碼行數:31,代碼來源:index.php


注:本文中的pagination::showPagination方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。