Example #1
0
 protected function page($_total, $_pagesize = PAGE_SIZE)
 {
     $_page = new Page($_total, $_pagesize);
     $this->_model->limit = $_page->limit;
     $this->_tpl->assign('page', $_page->showpage());
     $this->_tpl->assign('num', ($_page->page - 1) * $_pagesize);
 }
Example #2
0
 protected function page($_pagesize = PAGE_SIZE, $_model = null)
 {
     if (!Validate::isNullString($_model)) {
         $this->_model = $_model;
     }
     $_page = new Page($this->_model->total(), $_pagesize);
     $this->_model->setLimit($_page->getLimit());
     $this->_tpl->assign('page', $_page->showpage());
     $this->_tpl->assign('num', ($_page->getPage() - 1) * $_pagesize);
 }
Example #3
0
									<thead>
										<tr>
											<th>#ID</th>
											<th>域名</th>
											<th>所属用用户</th>
											<th>更新时间</th>
											<th class="text-right">操作</th>
										</tr>
									</thead>
									<tbody>
									<?php 
if (!empty($list)) {
    foreach ($list as $value) {
        echo '<tr id="List_' . $value['record_id'] . '"><td>' . $value['record_id'] . '</td><td>' . $value['name'] . '.' . $value['domain_name'] . '</td><td>' . $value['user'] . '</td><td>' . $value['updatetime'] . '</td><td align="right"><a href="http://' . $value['name'] . '.' . $value['domain_name'] . '" target="_Blank" class="dns-btn btn-info"><span class="glyphicon glyphicon-eye-open"></span></a>&nbsp;&nbsp;<span class="dns-btn btn-warning delRecord" domain_id=' . $value['domain_id'] . ' record_id="' . $value['record_id'] . '"><span class="glyphicon glyphicon-trash"></span></span></td></tr>';
    }
    echo '<tr><td colspan=5 align=center>' . $page->showpage() . '</td></tr>';
}
?>
									</tbody>
								</table>
							</div>
						</div>
					</div>
				</div>
                
            </div>

<script type="text/javascript">
function loadScript(c) {
	var a = document.createElement("script");
	a.onload = a.onreadystatechange = function() {
Example #4
0
        echo $value->id;
        ?>
" target="_blank">
			<img src="photo/<?php 
        echo $value->bigimg_path;
        ?>
" width="210" height="150" alt="" onload="DrawImage(this,100,247) " />
		</a>
		<?php 
        echo trim(trim($value->img_tag) . ' ' . trim($value->user_tag));
        ?>
		</p>
	</div>

<?php 
    }
}
?>




</div>
</section>
<div id="page"><?php 
echo $page->showpage();
?>
</div>

</body>
</html>
Example #5
0
<?php

/**
 * Created by PhpStorm.
 * User: wangyi
 * Date: 16/2/27
 * Time: 00:53
 */
require_once "Page.php";
$total = 100;
$pagesize = 10;
$page = new Page($total, $pagesize);
$pageshow = $page->showpage();
echo $pageshow;