</tr> </thead> <tbody id="alter_rows"> <?php $count_record = Client::countClient(); if (!isset($_REQUEST['page'])) { $page = 1; } else { $page = $_GET[page]; } $pagination = new Pagination(); //for display $pg = $pagination->page_pagination(20, $count_record, $page, 20); //$result_prod = mysql_query($query_Recordset2.$pg[1]); $client = Client::findAll($pg[1]); ?> <? if($count_record == 0) { ?> <tr> <td colspan="6" align="center" style="font-family:Arial, Helvetica, sans-serif; font-size:12px; color:#F00; font-weight:bold">No Record Found</td> </tr> <? } else { foreach($client as $clients) { ?> <tr> <td> <?php echo $clients->fldClientID; ?> </td> <td><?php
<?php $page = isset($_GET['page']) ? $_GET['page'] : 1; if (!preg_match('/^\\d+$/', $page)) { dispatch('core/backend/404'); exit; } $objects = Client::findAll(); $html = new HTML(); $html->renderOut('core/backend/html_header', array('title' => i18n(array('en' => 'Client', 'zh' => '客户'))), true); $html->output('<div id="wrapper">'); $html->renderOut('core/backend/header'); $perpage = 50; $total = Client::countAll(); $total_page = ceil($total / $perpage); $html->renderOut('client/backend/client_list', array('objects' => Client::findAllWithPage($page, $perpage), 'current_page' => $page, 'total_page' => $total_page, 'total' => $total, 'pager' => $html->render('core/components/pagination', array('total' => $total_page, 'page' => $page)), 'start_entry' => ($page - 1) * $perpage + 1, 'end_entry' => min(array($total, $page * $perpage))), true); $html->output('</div>'); $html->renderOut('core/backend/html_footer'); exit;
</div><!--/.nav-collapse --> </div> </nav> <div class="container"> <div class="row"> <div class="jumbotron text-center"> <div class="container"> <h1>Client Listing Test</h1> </div> </div> </div> <div class="row"> <div class="col-lg-6 col-lg-offset-3"> <div id="tabs"> <?php $clients = Client::findAll(); // var_dump( $clients[0]); $tabNum = 1; $offset = 1; $step = 40; $total = count($clients); // Echo the code for creating the Tabs in jQuery-UI // for( $j = 1; $j < ( $total/$step ) + 1; $j++) { echo "<ul>"; for ($j = 1; $j < 10; $j++) { echo "<li><a href='#tab-{$tabNum}'>{$tabNum}</a></li>"; $tabNum++; } echo "</ul>"; $tabNum = 1; // for( $j = 1; $j < ( $total/$step ) + 1; $j++) {