Ejemplo n.º 1
0
// $rs1=phongthuyBUS::getHinhAnh();
$curPage = 1;
$totalItems = null;
$business = null;
if (isset($_REQUEST['page'])) {
    $curPage = $_REQUEST['page'];
}
$maxItems = 5;
$maxPages = 25;
$offset = ($curPage - 1) * $maxItems;
$strLink = "phongthuy.php?";
$strSQL = "select * from phongthuy";
//$strSQL1="select * from hinhanh where idconnect=1";
$strCountSQL = str_replace("*", " count(*) ", $strSQL);
//$strCountSQL1=str_replace("*"," count(*) ",$strSQL1);
$totalItems = phongthuyBUS::countAllBySQL($strCountSQL);
//$totalItems1=phongthuyBUS::countAllBySQL($strCountSQL1);
$strSQL .= " limit {$offset},{$maxItems}";
//$strSQL1.=" limit $offset,$maxItems";
$business = phongthuyBUS::getAllBySQL($strSQL);
echo phongthuyBUS::display($strLink, $business, $totalItems, $curPage, $maxPages, $maxItems);
?>
							</div>
						</td>
					</tr>
				</table>
			</td>
		</tr>
</table>     
                         
<?php