摘要: <?php class SepPage{ var $db; //pdo实例 var $sqlStr; //数据库查询语句 var $nowPg; //当前页 var $pageSize; //每页显示的记录数 function ShowPage($db, $sqlStr, $pageSize, $nowPg){ $this->db = $db; $this->sqlStr = $sqlStr; $this->pageSize = $pageSize; if (!isset($nowPg) || ($nowPg == '') || ($nowPg == 0 阅读全文
posted @ 2013-02-01 09:15 hasayaki 阅读(889) 评论(0) 推荐(0) 编辑
摘要: // JavaScript Document var where = new Array(35); function comefrom(loca,locacity) { this.loca = loca; this.locacity = locacity; } where[0]= new comefrom("省份","城市"); where[1] = new comefrom("北京","|东城|西城|崇文|宣武|朝阳|丰台|石景山|海淀|门头沟|房山|通州|顺义|昌平|大兴|平谷|怀柔|密云|延庆"); wher 阅读全文
posted @ 2013-02-01 09:10 hasayaki 阅读(257) 评论(0) 推荐(0) 编辑
摘要: // JavaScript Document var $ = function(id) { return ('string' == typeof id ? document.getElementById(id) : id); }; var Extend = function(destination, source) { for(var pro in source) { destination[pro] = source[pro]; } return destination; } var addEvent = function(obj, type, fn) { if(obj.ad 阅读全文
posted @ 2013-02-01 09:07 hasayaki 阅读(416) 评论(0) 推荐(0) 编辑
摘要: <?phprequire("smarty/Smarty.class.php");class SmartyProject extends Smarty{ function __construct(){ parent::__construct(); $this->template_dir="./"; $this->compile_dir="./system/templates_c/"; $this->config_dir="./system/configs/"; $this->cache_ 阅读全文
posted @ 2013-02-01 09:02 hasayaki 阅读(150) 评论(0) 推荐(0) 编辑
摘要: <?php/** * 分页 * @category 功能 * @param $total:信息总数 * @param $displaypg:每页显示信息数,这里设置为默认是20; * @param $url:分页导航中的链接,除了加入不同的查询信息“page”外的部分都与这个URL相同.默认值本该设为本页URL(即$_SERVER["REQUEST_URI"]),但设置默认值的右边只能为常量,所以该默认值设为空字符串,在函数内部再设置为本页URL。 * @return string */ function pageft($total, $displaypg=10, $ 阅读全文
posted @ 2013-02-01 09:00 hasayaki 阅读(225) 评论(0) 推荐(0) 编辑
摘要: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=utf- 阅读全文
posted @ 2013-02-01 08:58 hasayaki 阅读(383) 评论(0) 推荐(0) 编辑