当前位置: 首页>>代码示例>>PHP>>正文


PHP pageft函数代码示例

本文整理汇总了PHP中pageft函数的典型用法代码示例。如果您正苦于以下问题:PHP pageft函数的具体用法?PHP pageft怎么用?PHP pageft使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了pageft函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: is_file

    $img_url = is_file($img_url) ? $img_url : $img_def_url;
    $post_date = substr($post->post_date, 0, 10);
    echo "<h3>[<a href='/fenlei' target='_blank'>分类</a>]<a href='/post/{$post->id}.html' target='_blank'>" . $post->post_title . "</a></h3>";
    echo "<figure><img src='" . $img_url . "'></figure>";
    echo "<ul><p>" . mb_substr(strip_tags($post->post_content), 0, 300, 'gb2312') . "</p></ul>";
    echo '<div class="dateview"><a title="' . $post->post_title . '" href="/post/' . $post->id . '.html" target="_blank" class="readmore">阅读全文>></a><span>' . $post_date . '</span><span>阅读(10)</span><span>评论(2)</span> <a href="javascript:(0)" class="post-like" data-pid="533" data-event="like"><i class="glyphicon glyphicon-thumbs-up"></i>赞(0)</a></span></div>';
}
//print_r($posts->lastPage());
//$cur_page = $_GET['page'];
$total = $posts->total();
//总文章数
$count_page = $posts->count();
//总页数
$url = $_SERVER['HTTP_HOST'];
//getPageHtml($cur_page,$count_page);
echo '<div class="quotes">' . pageft($total, 5) . '</div>';
//echo '<div class="badoo">'.$posts->render().'</div>';
//echo $posts->render();
?>
@stop

@section('rank')
	<li><a href="/" title="Column 三栏布局 个人网站模板" target="_blank">Column 三栏布局 个人网站模板</a></li>
	<li><a href="/" title="with love for you 个人网站模板" target="_blank">with love for you 个人网站模板</a></li>
	<li><a href="/" title="免费收录网站搜索引擎登录口大全" target="_blank">免费收录网站搜索引擎登录口大全</a></li>
	<li><a href="/" title="做网站到底需要什么?" target="_blank">做网站到底需要什么?</a></li>
	<li><a href="/" title="企业做网站具体流程步骤" target="_blank">企业做网站具体流程步骤</a></li>
	<li><a href="/" title="建站流程篇——教你如何快速学会做网站" target="_blank">建站流程篇——教你如何快速学会做网站</a></li>
	<li><a href="/" title="box-shadow 阴影右下脚折边效果" target="_blank">box-shadow 阴影右下脚折边效果</a></li>
	<li><a href="/" title="打雷时室内、户外应该需要注意什么" target="_blank">打雷时室内、户外应该需要注意什么</a></li>
@stop
开发者ID:kubill,项目名称:lumen,代码行数:31,代码来源:index.blade.php

示例2: mysqli_query

<?php 
} else {
    ?>
	  
	  
	    <ul>
<?php 
    if ($pro_class) {
        $tj = "where pro_class='{$pro_class}' order by id desc";
    } else {
        $tj = "order by id desc";
    }
    $sql = "select * from {$pro_table} {$tj} ";
    $res = mysqli_query($conn, $sql);
    $total = mysqli_num_rows($res);
    pageft($total, 16);
    $sql = "select * from {$pro_table} {$tj} limit {$firstcount},{$displaypg}";
    //echo $sql;
    $res = mysqli_query($conn, $sql);
    while ($rows = mysqli_fetch_assoc($res)) {
        $img_arr = explode('/', $rows['img']);
        $img_url = "img/" . $img_arr[0];
        ?>
		
		  <li><a href="show_details.php?id=<?php 
        echo $rows['id'];
        ?>
&pro_class=<?php 
        echo $rows['pro_class'];
        ?>
" target="_blank"><img src="<?php 
开发者ID:hedm0423,项目名称:van,代码行数:31,代码来源:show.php

示例3: urlencode

        if (empty($param)) {
            $param = "keyword=" . urlencode($keyword);
        }
    }
}
if (isset($_GET[classcode]) && !empty($_GET[classcode])) {
    $classcode = $_GET[classcode];
    $where = $where . "and prod_class={$classcode} ";
}
//echo "<script>alert(keyword==='" . $_POST[keyword] . "');</script>";
$pagesize = 12;
//一页显示多少条
//分页
$queryTotal = $db->query("select id from prod" . $where);
$total = $db->db_num_rows();
pageft($total, $pagesize, '', $param);
if ($firstcount < 0) {
    $firstcount = 0;
}
//列表
$prodQuery = $db->query("select * from prod " . $where . " order by create_date desc limit {$firstcount}, {$displaypg} ");
$prodList = array();
while ($row = $db->fetch_array($prodQuery)) {
    $prodList[] = $row;
}
$smarty->assign("prodList", $prodList);
//显示分页的内容
$smarty->assign("page", $pagenav);
//当前位置
$address = "您当前位置:首 页 &gt; <font color='#FF3300'>产品展示</font>";
$smarty->assign("address", $address);
开发者ID:soross,项目名称:myteashop,代码行数:31,代码来源:prodlist.php

示例4: utf8Substr

 */
include_once './header.php';
include_once './admin/conn/conn.php';
include_once './admin/conn/page.class.php';
// 截取中文字符
function utf8Substr($str, $from, $len)
{
    return preg_replace('#^(?:[\\x00-\\x7F]|[\\xC0-\\xFF][\\x80-\\xBF]+){0,' . $from . '}' . '((?:[\\x00-\\x7F]|[\\xC0-\\xFF][\\x80-\\xBF]+){0,' . $len . '}).*#s', '$1', $str);
}
$pageSize = 5;
// 每页显示的记录数
$sql0 = "select * from  tb_people order by votes desc,name asc";
$result0 = $mysqli->query($sql0);
$total = $mysqli->affected_rows;
// 查询总记录!
pageft($total, $pageSize, 1, 1, 1, 9, 20, 1);
$sql = "select * from  tb_people order by votes desc,name asc limit {$firstcount},{$pageSize}";
$result = $mysqli->query($sql);
$count = $mysqli->affected_rows;
?>

<div class="votes_content" style="background-color:#FFF5D0 ">
    <!--  左   -->
    <div class="votes_left">
        <?php 
while ($row1 = $result->fetch_assoc()) {
    ?>
            <span>
                <a href="./every.php?vid=<?php 
    echo base64_encode($row1['id']);
    ?>
开发者ID:honj51,项目名称:vote,代码行数:31,代码来源:ranking.php

示例5: array

<?php

require_once "../action/global_action.php";
//产品分类
$queryProdClass = $db->query("select * from prod_class");
$rowPC = array();
while ($rowProdClass = $db->fetch_array($queryProdClass)) {
    $rowPC[] = $rowProdClass;
}
$smarty->assign("prodClassList", $rowPC);
$result = @mysql_query("select id from prod where state='1'");
$total = @mysql_num_rows($result);
pageft($total, 10);
if ($firstcount < 0) {
    $firstcount = 0;
}
//列表
$query = $db->query("select a.class_name,b.* from prod_class a,prod b where a.id =b.prod_class and b.state='1' order by b.create_date desc limit {$firstcount}, {$displaypg}");
$prodList = array();
while ($row = $db->fetch_array($query)) {
    $prodList[] = $row;
}
$smarty->assign("caseList", $prodList);
$smarty->assign("cpage", $page);
$smarty->assign("page", $pagenav);
$smarty->display("case/caselist.html");
开发者ID:soross,项目名称:myteashop,代码行数:26,代码来源:caselist.php

示例6: pageft

<?php

require_once "action/checkAamsLogin.php";
require_once "action/smarty_inc.php";
require_once "action/mysql.class.php";
require_once "action/page.class.aams.php";
$remark = '新增';
if (isset($_GET[remark]) && "OK" == $_GET[remark]) {
    $remark = '已处理';
}
$pagesize = 15;
//一页显示多少条
//分页
$queryTotal = $db->query("select id from message where type='ADVISE' and remark='{$remark}'");
$total = $db->db_num_rows($queryTotal);
pageft($total, $pagesize);
if ($firstcount < 0) {
    $firstcount = 0;
}
//新闻列表
$newsQuery = $db->query("select * from message where type='ADVISE' and  remark='{$remark}' order by create_date desc limit {$firstcount}, {$displaypg}");
$newsRow = array();
while ($rownews = $db->fetch_array($newsQuery)) {
    $newsRow[] = $rownews;
}
$smarty->assign("messageRow", $newsRow);
//显示分页的内容
$smarty->assign("page", $pagenav);
$smarty->display("advise.html");
开发者ID:soross,项目名称:myteashop,代码行数:29,代码来源:advise.php

示例7: while

if ($dberp->nf()) {
    while ($dberp->next_record()) {
        $suppid = $dberp->f(fd_supp_id);
        $arr_suppname[$suppid] = $dberp->f(fd_supp_name);
    }
}
//ËÑË÷
if (empty($search)) {
    $querywhere = "";
} else {
    $querywhere = "where fd_supplierlogo_id like '%{$content}%'";
}
$query = "select fd_supplierlogo_id,fd_supplogo_suppid from web_conf_supplierlogo  {$querywhere}";
$db->query($query);
$total = $db->nf();
pageft($total, 10, $str_url);
if ($firstcount < 0) {
    $firstcount = 0;
}
$query = "{$query} limit {$firstcount},{$displaypg}";
$db->query($query);
if ($db->nf()) {
    while ($db->next_record()) {
        $fd_supplierlogo_id = $db->f(fd_supplierlogo_id);
        $fd_supplogo_suppid = $db->f(fd_supplogo_suppid);
        $fd_supplogo_suppname = $arr_suppname[$fd_supplogo_suppid];
        $result = uploadshow($fd_supplogo_suppid, $scatid);
        $thum = $result["thumurl"];
        $thum = $thum ? "<img src='{$g_showpic}{$thum}' />" : "";
        $e = '<a href=javascript:supploge("' . $g_uppic . '","' . $scatid . '","' . $fd_supplogo_suppid . '"); >ÐÞ¸Ä</a>';
        $a = '<a href=javascript:deleteimg("' . $g_uppic . '","' . $scatid . '","' . $fd_supplogo_suppid . '");>ɾ³ý</a>';
开发者ID:Xiaoyuyexi,项目名称:client-server,代码行数:31,代码来源:supplogo.php

示例8: mysql_query






<div id="pro_list">
        <ul style="width:95%;">
<?php 
$tj = " ";
$sql = "select * from {$table} {$tj}";
//echo $sql;
$res = mysql_query($sql);
if ($res) {
    $total = mysql_num_rows($res);
}
pageft($total, 12);
$sql = "select * from {$table} {$tj} order by id desc limit {$firstcount},{$displaypg} ";
$res = mysql_query($sql, $conn);
if (strlen($res) == 0) {
    echo "没有此类数据";
} else {
    while ($rows = mysql_fetch_array($res)) {
        $img_arr = explode('/', $rows['img']);
        $flod = "../img/";
        $img_url = $flod . $img_arr[0];
        ?>
		
		
          <li><a href="case_add.php?id=<?php 
        echo $rows['id'];
        ?>
开发者ID:hedm0423,项目名称:van,代码行数:26,代码来源:case.php

示例9: is_file

    $img_def_url = '/images/thumbnail.png';
    $img_url = $web_url . $img_url;
    //echo $img_url;
    $img_url = is_file($img_url) ? $img_url : $img_def_url;
    $content = mb_substr(strip_tags($post->post_content), 0, 80, 'UTF-8');
    $post_date = substr($post->created_at, 0, 10);
    echo "<article class='excerpt excerpt-1'>\n\t\t<a target='_blank' class='focus' href='/post/{$post->id}.html'><img src='{$img_url}' class='thumb' style='display: inline;'/></a>\n\t\t<header><a class='cat' href='/fenlei'>分类<i></i></a> <h2><a target='_blank' href='/post/{$post->id}.html' title='{$post->post_title}'>{$post->post_title}</a></h2></header>\n\t\t<p class='meta'><time><i class='fa fa-clock-o'></i>{$post_date}</time><a target='_blank' class='pc' href='/post/{$post->id}.html#comments'><i class='fa fa-comments-o'></i><span class='ds-thread-count' data-thread-key='{$post->id}' data-count-type='comments'></span></a></p>\n\t\t<p class='note'>{$content}</p>\n\t\t<a target='_blank' href ='/post/{$post->id}.html' class='cat' style='float:right'>阅读全文</a>\n\t\t</article>";
}
$total = $posts->total();
//总文章数
$count_page = $posts->count();
//总页数
$total_page = $posts->total();
$url = $_SERVER['HTTP_HOST'];
//getPageHtml($cur_page,$count_page);
echo '<div class="pagination"><ul>' . pageft($total, 5) . '</ul></div>';
?>
	<script>
		function highlight(idVal, keyword) {
			var textbox = document.getElementById(idVal);
			if ("" == keyword) return;
			var temp = textbox.innerHTML;
			console.log(temp);
			var htmlReg = new RegExp("\<.*?\>", "i");
			var arr = new Array();
			for (var i = 0; true; i++) {
				var tag = htmlReg.exec(temp);
				if (tag) {
					arr[i] = tag;
				} else {
					break;
开发者ID:kubill,项目名称:lumen,代码行数:31,代码来源:search.blade.php

示例10: pageft

include_once 'js/headPHP.php';
include_once 'page.php';
include_once "connect.php";
if (!$_SESSION['admin']) {
    echo "<script>alert('你不是管理员!');location.href = 'index.php'</script>";
    exit;
}
$sql = "select * from userlist";
$result = $dbh->query($sql);
/*$result = mysql_query($sql);*/
/*$cout_rows = mysql_num_rows($result);*/
$cout_rows = $result->rowCount();
//引用分页函数
$pagecount = 3;
//每页条数
pageft($cout_rows, $pagecount, $cout_rows);
$sql .= " limit {$firstcount}, {$displaypg}";
/*$result = mysql_query($sql);*/
$result = $dbh->query($sql);
?>
<body>
<h2 style="text-align: center;padding-bottom: 20px;">会员管理系统</h2>
<div class="container">
	<div style="height: 400px">
<table border="1" align="center" cellpadding="8" cellspacing="0" style="background-color: #fff;"  class="table table-hover table-condensed table-bordered">

	<tr align="center" style=" font-weight: bold" width="100%">
			<td width="10%">序号</td>
			<td width="20%">用户名</td>
			<td width="30%">爱好</td>
			<td width="15%">是否管理员</td>
开发者ID:RookieCookie,项目名称:TEST_votedSystem,代码行数:31,代码来源:adminList.php

示例11: mysql_query

        </tr></form>
      </table></td></tr>
</table>
  <tr><td  bgcolor="#FFFFFF"><table width="99%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#000000">
    <tr bgcolor="#E4E4E4">
      <td width="36%" height="25" align="center" bgcolor="#E4E4E4"><b>产品分类</b></td>
      <td width="22%" align="center" bgcolor="#E4E4E4"><b>产品名称</b></td>
      <td width="11%" align="center" bgcolor="#E4E4E4"><b>上传日期</b></td>
      <td width="9%" align="center" bgcolor="#E4E4E4"><b>操作</b></td>
    </tr>
<?php 
$sql = "select * from {$table} {$tj}";
//echo $sql;
$res = mysql_query($sql, $conn);
$total = mysql_num_rows($res);
pageft($total, 15);
$sql = "select * from {$table} {$tj} order by id desc limit {$firstcount},{$displaypg} ";
$res = mysql_query($sql, $conn);
if (strlen($res) == 0) {
    echo "没有此类数据";
} else {
    while ($rows = mysql_fetch_array($res)) {
        ?>
    <tr bgcolor="#EFEFEF">
      <td height="25" align="left" style="padding-left:2px;" bgcolor="#FFFFFF">
	  <?php 
        echo "<b>" . name($nav_table, $rows['pro_class1']) . "</b>" . " <span style='font-weight:blod;color:red'>></span> ";
        ?>
	  <?php 
        if ($rows['pro_class1'] == $rows['pro_class']) {
        } else {
开发者ID:hedm0423,项目名称:van,代码行数:31,代码来源:product.php

示例12: count

           <a href ="<?php 
echo $url_this . 'gty=3';
?>
" ><img src="images/female.gif"></a>
          </div>
         </div>        
		</td>
       </tr>
	   
	   
	   
<?php 
include_once "page.class.php";
$pageSize = $wpdb->get_var($wpdb->prepare("SELECT config_value FROM {$wpdb->config} where config_key='pagesize';"));
$total = count(style_display(0, 0, $_GET['style_keyword']));
pageft($total, $pageSize, 1, 0, 0, 9, 10, 0);
/* gty 0 默认排序,1, 中性排序,2, 女性排序, 3,男性排序*/
$gty = (int) $_GET['gty'];
//未传递参数,设置为默认排序
if (!isset($gty)) {
    $gty = 0;
}
$M_styles = style_display($firstcount, $pageSize, $_GET['style_keyword'], $gty);
?>
	   
	   <tr>
	    <td><div id="nav_pages"><?php 
echo $pagenav;
?>
</div></td>
	   </tr>
开发者ID:dalinhuang,项目名称:styleshop,代码行数:31,代码来源:index.php

示例13: Template

        break;
}
$t = new Template('.', "keep");
$t->set_file("supplogo", "supplogo.html");
$t->set_block("supplogo", "BXBK", "bxbks");
$scatid = 10;
//搜索
if (empty($search)) {
    $querywhere = "";
} else {
    $querywhere = "where fd_supplogo_suppname like '%{$content}%'";
}
$query = "select fd_supplierlogo_id,fd_supplogo_suppid,fd_supplogo_suppname,fd_supplogo_tuijian from web_conf_supplierlogo \n  {$querywhere} order by fd_supplogo_tuijian desc ";
$db->query($query);
$total = $db->nf();
pageft($total, 7, $str_url);
if ($firstcount < 0) {
    $firstcount = 0;
}
$query = "{$query} limit {$firstcount},{$displaypg}";
$db->query($query);
if ($db->nf()) {
    while ($db->next_record()) {
        $fd_supplierlogo_id = $db->f(fd_supplierlogo_id);
        $fd_supplogo_suppid = $db->f(fd_supplogo_suppid);
        $fd_supplogo_suppname = $db->f(fd_supplogo_suppname);
        $fd_supplogo_tuijian = $db->f(fd_supplogo_tuijian);
        $getFileimg = new AutogetFile();
        $csp_get_img = explode("@@", $getFileimg->AutogetFileimg($scatid, $fd_supplierlogo_id));
        $thumimg = $csp_get_img[0];
        $thumimg = $thumimg ? "<img src='" . $thumimg . "' width=120 height=50/>" : "";
开发者ID:Xiaoyuyexi,项目名称:client-server,代码行数:31,代码来源:supplogo.php

示例14: pageft

         } else {
             $openidStr = "null";
             //未关注
         }
     }
     $pageSize = "5";
     $page = $_GET['page'];
     $count = C::t("#smart_vote#smart_vote")->count_all();
     if ($page == "" || !isset($page)) {
         $query = C::t("#smart_vote#smart_vote")->fetch_all('0', '5');
         pageft($count, $pageSize, 1, 0, 0, 3);
     } else {
         $firstcount = ($page - 1) * $pageSize;
         // $lastcount = $page * $pageSize;
         $query = C::t("#smart_vote#smart_vote")->fetch_all($firstcount, $pageSize);
         pageft($count, $pageSize, 1, 0, 0, 3);
     }
     // pageft($count,10);
     include template("smart_vote:index");
 } else {
     if ("value" == $_GET['model']) {
         $openid = $_COOKIE["openid"];
         //openid
         $today = time();
         $exitdate = strtotime(date('Y-m-d 23:59:59'));
         $geetest = new GeetestLib();
         $geetest->set_privatekey("465719ad89db5cbe489cc051ff81a38e");
         $voteid = $_POST['voteid'];
         if (isset($_POST['geetest_challenge']) && isset($_POST['geetest_validate']) && isset($_POST['geetest_seccode'])) {
             $result = $geetest->validate($_POST['geetest_challenge'], $_POST['geetest_validate'], $_POST['geetest_seccode']);
             if ($result == TRUE) {
开发者ID:ljhchshm,项目名称:smart_vote,代码行数:31,代码来源:smart_vote.inc.php

示例15: DB_test

$db = new DB_test();
$db1 = new DB_test();
$t = new Template('.', "keep");
$t->set_file("mobilerecharge_list", "mobilerecharge_list.html");
$t->set_block("mobilerecharge_list", "HEADBXBK", "headbxbks");
$arr_state = array("请求交易", "交易成功", "交易取消", "无效状态");
//$arr_state = auto_charset($arr_state, 'utf-8', 'gbk');
if ($msgstart < 0) {
    $msgstart = 0;
}
$all_paymoney = 0;
$query = "select *,case\n        when fd_mrclist_payrq ='01' then '" . $arr_state[0] . "'\n        when fd_mrclist_payrq ='00' then '" . $arr_state[1] . "'" . "when fd_mrclist_payrq ='03' then '" . $arr_state[2] . "'\n        else '" . $arr_state[4] . "' END  fd_mrclist_payrq,\n        fd_mrclist_ofstate,\n       case\n        when fd_mrclist_ofstate ='1' then '<font color=blue>充值成功</font>'\n        when fd_mrclist_ofstate ='-1' then '正在充值'\n        else '<font color=red>充值失败</font>' END  ofstate\n         from  tb_mobilerechargelist\n          left join tb_author  on fd_author_id  = fd_mrclist_authorid\n          left join tb_sendcenter  on fd_sdcr_id  = fd_mrclist_sdcrid\n          where 1\n\t\t\tand  (fd_mrclist_payrq = '00') and fd_mrclist_sdcrid<100  order by fd_mrclist_id desc ";
$db->query($query);
//and fd_agpm_paytype <>'recharge'
$total = $db->num_rows($result);
pageft($total, $displaypg, $url);
if ($firstcount < 0) {
    $firstcount = 0;
}
$count = $firstcount;
$query = "{$query} limit {$firstcount},{$displaypg}";
$rows = $db->num_rows();
if ($db->execute($query)) {
    $arr_val = $db->get_all($query);
}
if (is_array($arr_val)) {
    foreach ($arr_val as $key => $arr_val) {
        $tcount++;
        if ($arr_val['fd_mrclist_ofstate'] != '1') {
            $arr_val['eidt_ofstate'] = '<a href="javascript:void(0);" name="' . $arr_val['fd_mrclist_authorid'] . '" class="eidt_ofstate" rel="' . $arr_val['fd_mrclist_bkntno'] . '">再次充值</a>';
        } else {
开发者ID:Xiaoyuyexi,项目名称:client-server,代码行数:31,代码来源:mobilerecharge_list.php


注:本文中的pageft函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。