<?php
function showMessage($urlstr,$title = 'Power by QQ:16953292,Msn:[email protected],Tel:13628392015')
{
$tS = '<html xmlns="http://www.w3.org/1999/xhtml">';
$tS .= '<head>';
$tS .= '<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />';
$tS .= '<title>'.$title.'</title>';
$tS .= '</head>';
$tS .= '<body>';
$tS .= '<div style="float:left;margin:100px 50px 50px 50px; padding:10px 10px 10px 10px;width:516px;border-bottom:1px solid #cbcbcb;border-left:1px solid #cbcbcb;border-top:1px solid #cbcbcb;border-right:1px solid #cbcbcb;font-size:12px">';
$tS .= $urlstr;
$tS .= '</div>';
$tS .= '</body>';
$tS .= '</html>';
return $tS;
}
function clean_html($string){
$search = array ("'<script[^>]*?>.*?</script>'si",
"'<[\/\!]*?[^<>]*?>'si",
"'([\r\n])[\s]+'",
"'&(quot|#34);'i",
"'&(amp|#38);'i",
"'&(lt|#60);'i",
"'&(gt|#62);'i",
"'&(nbsp|#160);'i",
"'&(iexcl|#161);'i",
"'&(cent|#162);'i",
"'&(pound|#163);'i",
"'&(copy|#169);'i",
"'&#(\d+);'e",
"'\"'si",
"'\''si");
$replace = array ("",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"“",
"‘");
$string = preg_replace ($search, $replace, $string);
return $string;
}
//分页
class ShowPage {
var $PageSize; //每页显示的记录数
var $Total; //记录总数
var $LinkAry; //Url参数数组,对于复合条件查询分页显示情况非常好用
var $PHP_SELF;
//取得总页数
function PageCount() {
$TotalPage = ($this->Total % $this->PageSize == 0) ? floor($this->Total / $this->PageSize) : floor($this->Total / $this->PageSize)+1;
return $TotalPage;
}
//取得当前页
function PageNum() {
$page = ((isset($_GET["page"])) != '') ? $_GET["page"] : $page = 1;
if (isset($_POST["page"])) $page = $_POST["page"];
if ($page < 1 ) $page =1;
return $page;
}
//查询语句定位指针
function OffSet() {
if ($this->PageNum() > $this->PageCount()) {
//$this->PageNum = $this->PageCount();
$pagemin = max(0,$this->Total - $this->PageSize - 1);
}else if ($this->PageNum() == 1){
$pagemin = 0;
}else {
$pagemin = min($this->Total - 1,$this->PageSize * ($this->PageNum() - 1));
}
return $pagemin . "," . $this->PageSize;
}
//定位首页
function FristPage() {
global $Aconf;
$LinkAry = $this->Url($this->LinkAry);
if($Aconf["rewrite"]){
$A = explode(".",$this->PHP_SELF);
$preFile = $A[0];
$strurl = ' <a href="'.$preFile.$LinkAry.'-1.html">首页</a> ';
$Frist = ($this->PageNum() <= 1) ? "" : $strurl;
}else{
$Frist = ($this->PageNum() <= 1) ? "" : "<a href=\"?page=1".$this->Url($this->LinkAry)."\">首页</a> ";
}
return $Frist;
}
//定位上一页
function PrePage() {
global $Aconf;
$prepage=$this->PageNum() - 1;
$LinkAry = $this->Url($this->LinkAry);
if($Aconf["rewrite"]){
$A = explode(".",$this->PHP_SELF);
$preFile = $A[0];
$strurl = ' <a href="'.$preFile.$LinkAry.'-'.$prepage.'.html">上一页</a> ';
$Previous = ($this->PageNum() >= 2) ? $strurl : "";
}else{
$Previous = ($this->PageNum() >= 2) ? " <a href=\"?page=".$prepage.$this->Url($this->LinkAry)."\">上一页</a> " : "";
}
return $Previous;
}
//定位下一页
function NextPage() {
global $Aconf;
$nextpage = $this->PageNum() + 1;
$LinkAry = $this->Url($this->LinkAry);
if($Aconf["rewrite"]){
$A = explode(".",$this->PHP_SELF);
$preFile = $A[0];
$strurl = ' <a href="'.$preFile.$LinkAry.'-'.$nextpage.'.html">下一页</a> ';
$Next = ($this->PageNum() <= $this->PageCount()-1) ? $strurl : "";
}else{
$Next = ($this->PageNum() <= $this->PageCount()-1) ? " <a href=\"?page=".$nextpage.$this->Url($this->LinkAry)."\">下一页</a> " : "";
}
return $Next;
}
//定位最后一页
function LastPage() {
global $Aconf;
$LinkAry = $this->Url($this->LinkAry);
if($Aconf["rewrite"]){
$A = explode(".",$this->PHP_SELF);
$preFile = $A[0];
$strurl = ' <a href="'.$preFile.$LinkAry.'-'.$this->PageCount().'.html">尾页</a> ';
$Last = ($this->PageNum() >= $this->PageCount()) ?" ": $strurl;
}else{
$Last = ($this->PageNum() >= $this->PageCount()) ? " " : " <a href=\"?page=".$this->PageCount().$this->Url($this->LinkAry)."\">尾页</a> ";
}
return $Last;
}
//下拉跳转页面
function JumpPage() {
$Jump = " 当前第 <b>".$this->PageNum()."</b> 页 共 <b>".$this->PageCount()."</b> 页 跳到 <select name=page onchange=\"javascript:location=this.options[this.selectedIndex].value;\">";
for ($i=1; $i<=$this->PageCount(); $i++) {
if ($i==$this->PageNum())
$Jump .= "<option value=\"?page=".$i.$this->Url($this->LinkAry)."\" selected>$i</option>";
else
$Jump .="<option value=\"?page=".$i.$this->Url($this->LinkAry)."\">$i</option> ";
}
$Jump .= "</select> 页 <b>[".$this->PageSize."条/页]共".$this->Total."条</b>";
return $Jump;
}
function JumpPage2() {
$Jump = "共 <b>".$this->PageCount()."</b> 页 转到 <select name=page onchange=\"javascript:location=this.options[this.selectedIndex].value;\">";
for ($i=1; $i<=$this->PageCount(); $i++) {
if ($i==$this->PageNum())
$Jump .= "<option value=\"?page=".$i.$this->Url($this->LinkAry)."\" selected>$i</option>";
else
$Jump .="<option value=\"?page=".$i.$this->Url($this->LinkAry)."\">$i</option> ";
}
$Jump .= "</select>";
return $Jump;
}
function JumpPage_num($num = 10) {
global $Aconf;
//$num 翻页偏移量
$nowpage = $this->PageNum();
$totalpage = $this->PageCount();
$totalnum = $this->Total;
$PageSize = $this->PageSize;
$LinkAry = $this->Url($this->LinkAry);
if($Aconf["rewrite"]){
$A = explode(".",$this->PHP_SELF);
$preFile = $A[0];
}
if($num > 0 ){
$j = ceil($nowpage / $num);
}else{
return false;
}
$num_satrt = ($j - 1) * $num;
$num_satrt = (!$num_satrt)?1:$num_satrt;
$num_end = $j * $num;
$num_end = ($num_end>$totalpage)?$totalpage:$num_end;
$strurl = '';
for ($i=$num_satrt; $i<=$num_end; $i++)
{
if($nowpage == $i) {
if($Aconf["rewrite"]){
$strurl .= ' <A HREF="'.$preFile.$LinkAry.'-'.$i.'.html" style="background-color:#FFCC00">'.$i.'</A> ';
}else{
$strurl .= ' <A HREF="'.$this->PHP_SELF.'?page='.$i.$LinkAry.'" style="background-color:#FFCC00">'.$i.'</A> ';
}
} else {
if($Aconf["rewrite"]){
$strurl .= ' <A HREF="'.$preFile.$LinkAry.'-'.$i.'.html">'.$i.'</A> ';
}else{
$strurl .= ' <A HREF="'.$this->PHP_SELF.'?page='.$i.$LinkAry.'">'.$i.'</A> ';
}
}
}
return $this->FristPage().' '.$this->PrePage().$strurl.' '.$this->NextPage().' '.$this->LastPage().' <a href="#" st
没有合适的资源?快使用搜索试试~ 我知道了~
基于PHP的行业之星单用户 php 开源免费建站系统.zip
共649个文件
php:154个
gif:131个
html:104个
1.该资源内容由用户上传,如若侵权请联系客服进行举报
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
版权申诉
0 下载量 88 浏览量
2023-08-29
00:20:08
上传
评论
收藏 1.79MB ZIP 举报
温馨提示
基于PHP的行业之星单用户 php 开源免费建站系统.zip
资源推荐
资源详情
资源评论
收起资源包目录
基于PHP的行业之星单用户 php 开源免费建站系统.zip (649个子文件)
incstar.sql.bak 24KB
command.php.bak 8KB
config.inc.php.bak 507B
editor.css 35KB
editor.css 31KB
editor.css 31KB
dialog.css 16KB
dialog.css 15KB
dialog.css 13KB
style.css 8KB
style.css 6KB
style.css 6KB
style.css 6KB
calendar.css 6KB
style.css 5KB
prettyPhoto.css 4KB
nave.css 4KB
nave_754970153.css 4KB
yui.css 3KB
admin.css 2KB
admin.css 2KB
templates.css 2KB
templates.css 1KB
templates.css 1KB
toolbar.css 1KB
wsc.css 1004B
contents.css 674B
admin_print.css 181B
mid-image.gif 63KB
menu.gif 9KB
1304942207874032846.gif 5KB
logo.gif 5KB
osunit_logo.gif 4KB
hand.gif 4KB
1305075999446340629.gif 3KB
bg-nav.gif 3KB
loader.gif 2KB
zoo.gif 1KB
zoo.gif 1KB
zoo.gif 1KB
zoo.gif 1KB
share.gif 1KB
imgbtn03.gif 1KB
imgbtn03.gif 1KB
imgbtn03.gif 1KB
imgbtn04.gif 1KB
imgbtn04.gif 1KB
imgbtn04.gif 1KB
uicolor.gif 1KB
icon_verf.gif 1KB
imgbtn05.gif 1004B
imgbtn06.gif 1004B
imgbtn06.gif 1004B
imgbtn05.gif 1004B
imgbtn06.gif 1004B
imgbtn05.gif 1004B
bg_user.gif 994B
bg-header.gif 852B
but_login_01.gif 732B
but_login_01.gif 732B
imgbtn01.gif 696B
imgbtn01.gif 696B
imgbtn01.gif 696B
imgbtn02.gif 695B
imgbtn02.gif 695B
imgbtn02.gif 695B
nav-top.gif 672B
bg-logo.gif 588B
icon_view.gif 576B
details.gif 470B
cry_smile.gif 468B
angel_smile.gif 465B
confused_smile.gif 464B
sad_smile.gif 460B
wink_smile.gif 458B
whatchutalkingabout_smile.gif 452B
omg_smile.gif 451B
regular_smile.gif 450B
shades_smile.gif 449B
tounge_smile.gif 446B
angry_smile.gif 443B
teeth_smile.gif 442B
embaressed_smile.gif 442B
devil_smile.gif 436B
envelope.gif 426B
template3.gif 422B
thumbs_down.gif 408B
thumbs_up.gif 396B
template1.gif 375B
lightbulb.gif 368B
hbar_right.gif 362B
hbar_right.gif 362B
btnClose.gif 361B
hbar_left.gif 356B
hbar_left.gif 356B
template2.gif 333B
art_icon.gif 317B
btnPrevious.gif 317B
cate_open.gif 313B
cate_open.gif 313B
共 649 条
- 1
- 2
- 3
- 4
- 5
- 6
- 7
资源评论
助力毕业
- 粉丝: 2177
- 资源: 5130
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功