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


PHP db_test::num_rows方法代碼示例

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


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

示例1: Template

<?php

require "../include/common.inc.php";
include "../include/pageft.php";
$db = new db_test();
$gourl = "authorpaycard_query.php";
$gotourl = $gourl . $tempurl;
require "../include/alledit.1.php";
$t = new Template(".", "keep");
$t->set_file("authorpaycard", "authorpaycard.html");
$t->set_block("authorpaycard_query", "prolist", "prolists");
if (!empty($listid)) {
    // 編輯
    $query = "select fd_agpm_bkntno as bkntno,\n\t\t\t\t count(fd_agpm_paycardid) as paynum,\t\t\n\t\t\t\t sum(fd_agpm_payfee) as payfee,\n\t\t\t\t sum(fd_agpm_sdcrpayfeemoney) as sdcrpayfeemoney,\n\t\t\t\t sum(fd_agpm_sdcragentfeemoney) as sdcragentfeemoney,\n\t\t\t\t fd_agpm_shoucardno as shoucardno,\n                 fd_agpm_shoucardbank as shoucardbank,\n\t\t\t\t fd_agpm_shoucardman as shoucardman,\n                 fd_agpm_shoucardmobile as shoucardmobile,\n\t\t\t\t fd_agpm_paytype as paytype,\n\t\t\t\t fd_agpm_paydate as paydate,\n\t\t\t\t fd_agpm_no as no,\n\t\t\t\t fd_agpm_id as agpmid,\t\n\t\t\t\t fd_author_truename as authorname,\n\t\t\t\t fd_paycard_key as paycardkey,\n\t\t\t\t fd_paycardtype_name as paycardtype,\n\t\t\t\t fd_paycard_scope as paycardscope,\n                 fd_agpm_paymoney as paymoney,\n\t\t\t\t fd_agpm_state as agpmstate,\n\t\t\t\t fd_paycard_batches as batches,\n\t\t\t\t fd_agpm_money as money,\n\t\t\t\t fd_agpm_paymoney as paymoney from tb_agentpaymoneylist   \n\t\t\t\t left join tb_author on fd_author_id = fd_agpm_authorid\n\t\t\t\t left join tb_paycard on fd_paycard_id = fd_agpm_paycardid\n\t\t\t\t left join tb_paycardtype on fd_paycardtype_id=fd_paycard_paycardtypeid\n               where fd_agpm_id ='{$listid}' group by fd_agpm_paycardid order by fd_agpm_no\n             ";
    $db->query($query);
    $total = $db->num_rows($result);
    pageft($total, 20, $url);
    if ($firstcount < 0) {
        $firstcount = 0;
    }
    $query = "{$query} limit {$firstcount},{$displaypg}";
    //echo $query;
    $db->query($query);
    $rows = $db->num_rows();
    $arr_result = $db->getFiledData('');
    foreach ($arr_result as $value) {
        $t->set_var($value);
        $cssy = $value[payfee] - $value[sdcrpayfeemoney] - $value[sdcragentfeemoney];
        $t->parse("prolists", "prolist", true);
    }
}
開發者ID:Xiaoyuyexi,項目名稱:client-server,代碼行數:31,代碼來源:authorpaycard.php


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