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


PHP Reports::get_reports方法代碼示例

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


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

示例1: Reports

require_once "../config.inc.php";
if (!empty($_REQUEST['page_start'])) {
    $page_start = $_REQUEST['page_start'];
} else {
    $page_start = "0";
}
if (!empty($_REQUEST['page_range'])) {
    $page_range = $_REQUEST['page_range'];
} else {
    $page_range = PAGING_RANGE;
}
$db = Database::obtain(DB_SERVER, DB_USER, DB_PASS, DB_DATABASE);
$db->connect();
$r = new Reports('unknown', BASE_DOMAIN);
if (empty($_REQUEST['uid'])) {
    $reports = $r->get_reports($page_start, $page_range);
    $reports_count = $r->count_reports();
} else {
    //get one report from search results
    $uid = $_REQUEST['uid'];
    $reports = $r->getReport($uid);
}
$pager_count = $reports_count;
//total records for query
$pager_range = PAGING_RANGE;
//total currently displayed
$pager_end = $page_start + $pager_range;
$pager_pos = $page_start;
$next_pos = $pager_range + 1;
$back_pos = $pager_pos;
$next_button = "";
開發者ID:autonomous019,項目名稱:fsi,代碼行數:31,代碼來源:reports.php

示例2:

                <th>Description</th>
				<th>File</th>
				<th>Delete</th>
            </tr>
        </thead>
		
	    <tbody>
	         

	<?php 
//require_once("../config.inc.php");
//$db = Database::obtain(DB_SERVER, DB_USER, DB_PASS, DB_DATABASE);
//$db->connect();
//$r = new Reports('unknown', BASE_DOMAIN);
if (!empty($_REQUEST['uid'])) {
    $reports = $r->get_reports();
} else {
    //get one report from search results
    $uid = $_REQUEST['uid'];
    $reports = $r->getReport($uid);
}
//$reports = $r->get_reports();
//print_r($reports);
$reports = $info;
for ($i = 0; $i < count($reports); $i++) {
    $id = $reports[$i]['id'];
    $name = $reports[$i]['name'];
    $location = $reports[$i]['location'];
    $file_info = $reports[$i]['file_info'];
    $description = $reports[$i]['description'];
    $client_id = $reports[$i]['client_id'];
開發者ID:autonomous019,項目名稱:fsi,代碼行數:31,代碼來源:settings_edit.php


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