include "../top.html"; ?> include "../cdbcon.inc"; if (!$page) { $page=1;} $pagesize=9; $listsize=10; //ÇÏ´Ü ¸®½ºÆ® °¹¼ö $query=mysql_query("select count(*) from $tname"); $ro=mysql_fetch_array($query); $total=$ro[0]; $lownumber=(($page-1)*$pagesize); $totalpage = ceil($total/$pagesize); //ÃÑÆäÀÌÁö¼ö $totalblock = ceil($totalpage/$listsize); //ÃÑºí·°¼ö $block=ceil($page/$listsize); //ÇöÀç ºí·° $first_page=($block-1)*$listsize; //ÇöÀçºí·°¿¡¼ Ãâ·ÂµÉ ù¹øÂ° ÆäÀÌÁö $last_page=$block*$listsize; //ÇöÀçºí·°¿¡¼ Ãâ·ÂµÉ ¸¶Áö¸· ÆäÀÌÁö if($block>=$totalblock){ $last_page=$totalpage; } $sql=mysql_query("select num,no,name,id,photo from students order by no asc limit $lownumber,$pagesize"); ?>
include "../left.html";?> |
|