📄 vread.php
字号:
<?php
include'include/begin.php';
include'include/vread.php';
$tp3 = array(20,21);
$tpl_html = 'vread';
$svread='';
$tid = (int)$_GET['tid'];
$fdown = array();
$result = mysql_query("select * from {$db_prefix}title where cid='$tid' && wid > 0 ", $myconn);
if ($trow = mysql_fetch_array($result)) {
if ($trow['state']<1 ) $userp2[9]?NULL:echoerror(71);
$wid = $trow['wid'];
$menufile = 'wmenu' . $wid;
wstyle($t4[$wid]);
include language();
include'include/main.php';
if (!$username && !$t2[$wid]) {
echoerror(77);
}
$trow['html']?$trow['title'] = strip_tags($trow['title']): null;
$tauthor = $trow['author'];
$twauthor = $trow['wauthor'];
$ttitle = htmlspecialchars($trow['title']);
$pagename_m = $_pagename[43];
$pagename_s = $ttitle;
$pagename_n = $wname[$wid];
$webnav=$wups[$wid]>0?$wname[$wups[$wid]]:$wname[$wid];
$fecho=$trow['fid']>0 && !$fuclose?'':'display: none;';
$tposttime = echotime($trow['posttime']);
$tposttimeup = echotime($trow['posttimeup']);
$thits = $trow['hits'];
$tflo = $trow['flo'];
$tegg = $trow['egg'];
$replies = $trow['replies'];
$wadmin = $trow['wadmin'];
$wposttime = echotime($trow['wposttime']);
} else {
echoerror(71);
}
$result = mysql_query("select * from {$db_prefix}posts where id='$trow[cid]' && tid='$trow[cid]'", $myconn);
if ($row = mysql_fetch_array($result)) {
$annex = $row['annex']?1 : null;
$html = explode('|', $row['html']);
$downnum = 0;
if ($annex) {
$annexs = '';
$annexresult = mysql_query("select * from {$db_prefix}annex where sign='$row[sign]'&& fix='1'" , $myconn);
while ($annexrow = mysql_fetch_array($annexresult)) {
$annexs[$annexrow['id']] = array('code' => $annexrow['code'], 'type' => $annexrow["type"], 'uptime' => $annexrow["uptime"], 'downuser' => $annexrow["downuser"], 'downnum' => $annexrow["downnum"], 'content' => $annexrow["content"], 'title' => $annexrow["title"], 'filetype' => $annexrow["filetype"], 'author' => $row["author"], 'size' => $annexrow["size"],);
if ($annexrow["code"] != "poll") {
$downnum += $annexrow["downnum"];
}
}
}
$page = is_numeric($_GET['page']) && $_GET['page'] > 0?$_GET['page']: 1;
$page = Ceil($page);
$contentarray = explode('[page]', $row['content']);
$numpage = count($contentarray);
if ($page > $numpage) {
echoerror(90);
}
$id = $page-1;
$content = $contentarray[$id];
$tpp=$trow['tpl']>0?$trow['tpl']:$t1[$wid];
$content = content($content);
$pagelist = '';
if (($numpage - $page) >= 5) {
$b = $page-5;
$c = $page + 5;
if (abs($b) != $b || $b == 0) {
$b = 1;
$c = 10;
}
$numpage <= 10?$c = $numpage: null;
} else {
$c = $numpage;
$b = $numpage-9;
if (abs($b) != $b || $b == 0) {
$b = 1;
}
}
for(;$b <= $c;$b++) {
$pagelist .= '<div class="page-'.($b == $page?2:1).'"><a href="'.(REWRIT_E?'vread-'.$tid.'-'.$b.'.html':'vread.php?tid=' . $tid . '&page=' . $b) . '">' . $b . '</a></div>';
}
if ($numpage > 10 && $numpage - $page > 5) {
$pagelist .= '<div class="page-1"><a>鈥
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -