?? index1.php
字號(hào):
<?php
session_start();
require "fun.php";
require "articlelib.php";
require "header.php";
require "config.php";
?>
<SCRIPT language=JavaScript>
<!--
var bV = parseInt(navigator.appVersion);
var NN4 = document.layers ? true : false;
var IE4 = document.all && bV >= 4 ? true : false;
var downloadID = 0;
var downloadHash = '';
var showClickprogress = 100;
function goPage(pagenum)
{
document.MainForm.page.value = pagenum;
document.MainForm.submit();
return false;
}
function Sort(type)
{
document.MainForm.sorttype.value = type;
document.MainForm.submit();
}
function SubmitForm()
{
document.MainForm.page.value = 1;
document.MainForm.submit();
}
function showTip(msg)
{
var obj = 'TipBox';
if (showClickprogress < 100) return;
if (typeof(hideTimeOut) != 'undefined') clearTimeout(hideTimeOut);
if (NN4)
{
if (document.layers[obj].visibility != 'visible')
{
with (document[obj].document)
{
open();
write('<layer id=TipBox bgColor=#ffffee style="width: 700px; border: 1px solid #000000" onMouseover="keepTip()" onMousewheel="keepTip()" onMouseout="hideTip()">' +msg+ '</layer>');
close();
}
var objp = document.layers.TipBox;
objp.moveTo(100, e.y + 6);
}
document.layers[obj].visibility = 'visible';
}
else if(IE4)
{
if (document.all[obj].style.visibility != 'visible')
{
document.all[obj].innerHTML = msg;
var y = event.y;
var objp = document.all.TipBox.style;
var yy = document.body.scrollTop + y + 6;
objp.pixelLeft = 100;
objp.pixelTop = yy;
}
document.all[obj].style.visibility = 'visible';
}
}
function keepTip()
{
var obj = 'TipBox';
if (showClickprogress < 100) return;
if (typeof(hideTimeOut) != 'undefined') clearTimeout(hideTimeOut);
if (NN4)
document.layers[obj].visibility = 'visible';
else if(IE4)
document.all[obj].style.visibility = 'visible';
}
function hideTip()
{
hideTimeOut = setTimeout('delayHide()', 5); //窗口消失時(shí)間,為方便用戶瀏覽,建議設(shè)置越小越好,原:300
}
function delayHide()
{
var obj = 'TipBox';
if (NN4)
{
if (document.layers[obj] != null)
document.layers[obj].visibility = 'hidden';
}
else if(IE4)
document.all[obj].style.visibility = 'hidden';
if (typeof(hideTimeOut) != 'undefined') clearTimeout(hideTimeOut);
}
function setReload()
{
window.location.reload();
}
function showDetail(info_hash)
{
var url = info_hash == '' ? 'viewgraph.php' : 'detail.php?info_hash=' + info_hash;
window.open(url, 'detailview', 'scrollbars=yes, width=500, height=300');
}
function GetTorrent()
{
torrentdir = Math.floor(downloadID / 2000);
document.location.href = 'torrents/'+torrentdir+'/'+downloadHash+'.torrent';
}
function displayClickAD()
{
showClickprogress = 0;
ClickADref = document.all.ClickAD;
var scroll_top = document.body.scrollTop;
var docwidth = document.body.clientWidth;
var docheight = document.body.clientHeight;
var ClickADwidth = ClickADref.offsetWidth;
var ClickADheight = ClickADref.offsetHeight;
ClickADref.style.left = docwidth / 2 - ClickADwidth / 2;
ClickADref.style.top = scroll_top + docheight / 2 - ClickADheight / 2;
ClickADscroll = setInterval('staticClickADbox()', 50);
ProgressBar = setInterval('controlledhideClickAD()', 400);
ClickADref.style.visibility = "visible";
}
function staticClickADbox()
{
var scroll_top = document.body.scrollTop;
var docheight = document.body.clientHeight;
var ClickADheight = ClickADref.offsetHeight;
ClickADref.style.top = scroll_top + docheight / 2 - ClickADheight / 2;
}
function hideClickADbox()
{
ClickADref.style.visibility = 'hidden';
if (typeof(ClickADscroll) != 'undefined') clearInterval(ClickADscroll);
if (typeof(ProgressBar) != 'undefined') clearInterval(ProgressBar);
document.all.Progress.innerHTML = '<table align=left><tr><td height=5></td></tr></table>';
GetTorrent();
}
function controlledhideClickAD()
{
showClickprogress += 10;
document.all.Progress.innerHTML = '<table width=' + showClickprogress + '% align=left bgColor=green><tr><td height=5></td></tr></table>';
if (showClickprogress > 100) hideClickADbox();
}
function DownLoad(id, hash)
{
downloadID = id;
downloadHash = hash;
hideTip();
IE4 ? displayClickAD() : GetTorrent();
}
var showPopStep = 10;
var popOpacity = 94; //原:80
var sPop = '';
var tFadeOut = 'yes'; //原:yes
function showPopupText(popText)
{
if (!IE4) return;
var o = event.srcElement;
var MouseX = event.x;
var MouseY = event.y;
if (popText != sPop)
{
sPop = popText;
clearTimeout(tFadeOut);
if (sPop == null || sPop == '')
{
document.all.popLayer.innerHTML = '';
document.all.popLayer.style.filter = "Alpha()";
document.all.popLayer.filters.Alpha.opacity = 0;
}
else
{
document.all.popLayer.innerHTML = sPop;
document.all.popLayer.style.filter = "Alpha(Opacity=0)";
var popWidth = document.all.popLayer.clientWidth;
var popHeight = document.all.popLayer.clientHeight;
document.all.popLayer.style.left = MouseX + popWidth > document.body.clientWidth - 5 ? document.body.clientWidth - popWidth - 5 : MouseX;
document.all.popLayer.style.top = MouseY + document.body.scrollTop;
fadeOut();
}
}
}
function fadeOut()
{
if (popLayer.filters.Alpha.opacity < popOpacity)
{
popLayer.filters.Alpha.opacity += showPopStep;
tFadeOut = setTimeout('fadeOut()', 1000); //窗口淡出時(shí)間設(shè)置 原:30
}
}
-->
</SCRIPT>
<SCRIPT language=JavaScript>
<!--
if (IE4)
{
//document.write('<div id=popLayer style="position:absolute; z-index:101" class=cPopText></div>');
document.write('<div id=ClickAD style="width: 700px; position: absolute; visibility: hidden; padding: 5px 5px 5px 5px; background-Color: #ffffee; filter: alpha(Opacity=94); border: 0px solid #000000; z-index: 100"><table cellPadding=0 cellSpacing=0 border=0 width=100% style="table-layout: fixed" align=center><tr><td style="word-wrap: break-word"><a href=http://www.lwcrystal.com target=_blank><img src=/ad/ad4.jpg border=0></a></td></tr></table><div id=Progress align=center><table align=left><tr><td height=5></td></tr></table></div></div>');
document.write('<div id=TipBox style="width: 700px; position: absolute; visibility: hidden; padding: 5px 5px 5px 5px; background-Color: #ffffee; filter: alpha(Opacity=94); border: 0px solid #000000; z-index: 99" onMouseover="keepTip()" onMousewheel="keepTip()" onMouseout="hideTip()"></div>');
}
else if (NN4)
{
document.write('<div id=TipBox style="position: absolute; visibility: hidden; background-Color: #ffffee; filter: alpha(Opacity=94); border: 0px solid #000000; z-index: 99"></div>');
setTimeout('window.onResize=setReload', 500);
}
-->
</SCRIPT>
<?php
$text_search = intval($_GET['fll']);
if (empty($nowpage))
{
$nowpage = 1;
}
$style_search="fl";
//返回查到的結(jié)果
if ($text_search != "")
{
$result = search_forum($style_search, $text_search);
}
if (!empty($result))
{
//查到的文章數(shù)
$total = mysql_num_rows($result);
$search_row = $page1;
//文章的頁數(shù)
$num_page = ceil($total/$search_row);
$ressearch = search_forum($style_search, $text_search);
//數(shù)用數(shù)組存儲(chǔ)所有的結(jié)果,也可以在前面采用sql中的limit方法,得到一定范圍的結(jié)果
while ($searticle = mysql_fetch_array($ressearch))
{
$info[] = $searticle;
}
$begin = ($nowpage-1)*$search_row;
$end = $nowpage*$search_row;
if ($begin <= 0)
{
$begin = 0;
}
if ($end >= $total)
{
$end = $total;
}
}
?>
<html>
<head>
<title><?=$sys_site_name?></title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link href="admin/template/css.css" rel="stylesheet" type="text/css" />
<!--
.STYLE4 {font-size: 16px}
.STYLE5 {color: #000000}
-->
</style>
</head>
<body bgColor="#FFFFFF">
<form name="search" method="post" action="search.php">
<input type="hidden" name="fll" value="<? print $fll;?>">
<input type="hidden" name="nowpage" value="<? print $nowpage;?>">
<table width="100%" border="0">
<input type="hidden" name="nowpage" value="<? print $nowpage;?>">
<input type="hidden" name="style_search" value="<? print $style_search;?>">
<input type="hidden" name="text_search" value="<? print $fll;?>">
<?php
if (is_array($info))
{
?>
<tr>
<table border=0 cellSpacing=1 width="100%">
<tbody>
<tr bgColor="#aeaeae">
<th align="left">
<div align="center">序號(hào) </div></th>
<th align="left">
<div align="center">分類 </div></th>
<th align="left">
<div align="center">標(biāo)題/簡介/種子 </div></th>
<th align="left">
<div align="center">作者 </div></th>
<th align="left">
<div align="center">下載次數(shù) </div></th>
<th align="left">
<div align="center">發(fā)布日期 </div></th>
</tr>
<?php
for ($i=$begin; $i<$end; $i++)
{ $num = $i+1;
$msg = $info[$i]["content"];
$id = $info[$i]["id"];
$title = $info[$i]["title"];
$writer = $info[$i]["writer"];
$size_article = $info[$i]["size_article"];
$num_click = $info[$i]["click"];
$importtime = $info[$i]["importtime"];
$adda= $info[$i]["adda"];
$fl= $info[$i]["fl"];
if (file_exists("$sys_data_dir/fl/$fl.php"))
{
$sort_data=file("$sys_data_dir/fl/$fl.php");
$songer_num=count($sort_data);
$sort_info=explode("|",$sort_data[$songer_num-1]);
}
else
{
echo "分類不存在!可能已經(jīng)刪除,請(qǐng)聯(lián)系站長!";
}
?>
<TR bgColor='#CCCCFF'>
<TD width='4%'><div align="center"><span class="STYLE3">
<?=$num;?>
</span> </div></TD>
<TD width='10%'>
<div align="center"><span class="STYLE3">
<?=$sort_info[0];?></span></div></TD>
<TD width='50%'>
<span class="STYLE3">
<a onMouseOut="hideTip()" onMouseOver="showTip('<?=$msg;?>')" target="_blank" href='info.php?id=<? print $id;?>'><? print $title;?></A></span></TD>
<TD width='9%'>
<div align="center"><span class="STYLE3">
<?=$writer;?></span></div></TD>
<TD width='5%'>
<div align="center"><span class="STYLE3">
<?=$num_click;?>
</span></div></TD>
<TD width='12%'>
<div align="center">
<?=$importtime;?></div></TD>
</TR> <?php
}
//調(diào)用分頁格式
print pri_page("index1", $fll, $nowpage, $num_page);
}
else
{
print "<tr>";
print "<td width='100%'>";
print "<div align='center'>";
$msg = "查詢結(jié)果為空!";
print $msg;
print "</div>";
print "</td>";
print "</tr>";
}
?>
</table>
</form>
</body>
</html>
<?php
db_close();
require "footer.php";
?>
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -