<?php
function bbscms_threadcontent($paras) {
global $d_basicset,$d_mainset,$l_mod_fore,$bbstype,$tablepre,$forumurl,$pid,$tid,$ifattach_detail,$dateformat,$noshowedaid,$img_maxwidth;
//--MAIN_START
$tablepre=$d_mainset['mod_setting']['bbscms']['tablepre'];
$forumurl=$d_mainset['mod_setting']['bbscms']['forumurl'];
$qmark= $d_mainset['mod_setting']['bbscms']['urlrewrite'] ? '' : '?';
$bbstype=$d_mainset['mod_setting']['bbscms']['bbstype'];
$nofids=$d_mainset['mod_setting']['bbscms']['fid_range'];
$tid=intval($_GET['tid']);
$page=intval($_GET['page'])>0 ? intval($_GET['page']) : 1;
$nopermstr='<script type="text/JavaScript">document.title="'.$l_mod_fore['nopermission'].'";</script><div style="margin:48px" align="center">'.$l_mod_fore['nopermission'].'</div>';
if (substr($bbstype,0,2)=='dz') {
$rectmp=db_fetch_array(db_query('SELECT fid,displayorder,readperm,price FROM '.$tablepre.'threads WHERE tid='.$tid));
if ($rectmp['displayorder']<0 or $rectmp['readperm']>0 or $rectmp['price']>0) return $nopermstr;
}elseif (substr($bbstype,0,2)=='pw') {
$rectmp=db_fetch_array(db_query('SELECT fid,ifcheck FROM '.$tablepre.'threads WHERE tid='.$tid));
if ($rectmp['ifcheck']<1) return $nopermstr;
}
if ($nofids!='') {
if (in_array($rectmp['fid'],$nofids)) return $nopermstr;
}
if (defined('JSMODE')) {
if (substr($bbstype,0,2)=='dz') {
db_query('UPDATE '.$tablepre.'threads SET views=views+1 WHERE tid='.$tid);
}elseif (substr($bbstype,0,2)=='pw') {
db_query('UPDATE '.$tablepre.'threads SET hits=hits+1 WHERE tid='.$tid);
}
exit();
}
$ifsmartread=intval($paras['ifsmartread']);
$title_maxlen= intval($paras['title_maxlen'])>0 ? intval($paras['title_maxlen']) : 36;
$title_fontsize= intval($paras['title_fontsize'])>0 ? intval($paras['title_fontsize']) : 18;
$title_fontname= trim(b64($paras['title_fontname']))!='' ? b64($paras['title_fontname']) : '';
$title_fontstyle= trim(b64($paras['title_fontstyle']))!='' ? b64($paras['title_fontstyle']) : '';
$content_fontsize= intval($paras['content_fontsize'])>0 ? intval($paras['content_fontsize']) : 14;
$content_fontname= trim(b64($paras['content_fontname']))!='' ? b64($paras['content_fontname']) : '';
$content_fontstyle= trim(b64($paras['content_fontstyle']))!='' ? b64($paras['content_fontstyle']) : '';
$contentadcode= trim(b64($paras['contentadcode']))!='' ? stripslashes(b64($paras['contentadcode'])) : '';
$dateformat= trim(b64($paras['dateformat']))=='' ? 'Y/n/j H:i' : b64($paras['dateformat']);
$img_maxwidth= intval($paras['img_maxwidth'])>0 ? intval($paras['img_maxwidth']) : 450;
$ifattach_detail=intval($paras['ifattach_detail']);
$ifshowreplies=intval($paras['ifshowreplies']);
$replies_maxnum= intval($paras['replies_maxnum'])>0 ? intval($paras['replies_maxnum']) : 10;
$threadcontent='';
$authornow='';
$authorprev='';
$noshowedpid='';
$noshowedaid='';
$showcount=0;
if (substr($bbstype,0,2)=='dz') {
$query=db_query('SELECT p.pid,p.author,p.subject,p.dateline,p.message,t.views,f.fid,f.fup,f.type,f.name FROM '.$tablepre.'posts p LEFT JOIN '.$tablepre.'threads t ON t.tid=p.tid LEFT JOIN '.$tablepre.'forums f ON f.fid=p.fid WHERE p.tid='.$tid.' ORDER BY dateline ASC');
while ($rec=db_fetch_array($query)) {
$showcount++;
$authornow=$rec['author'];
if (($ifsmartread==1 and ($authornow==$authorprev or $showcount==1)) or ($ifsmartread==0 and $showcount==1)) {
$pid=$rec['pid'];
$noshowedpid.=' AND pid!='.$pid;
if ($showcount==1) {
//Class Links
$classitemarray=array();
$i=-1;
if ($rec['type']=='sub') {
$rectemp1=db_fetch_array(db_query('SELECT fid,fup,name FROM '.$tablepre.'forums WHERE fid='.$rec['fup']));
$rectemp2=db_fetch_array(db_query('SELECT fid,name FROM '.$tablepre.'forums WHERE fid='.$rectemp1['fup']));
$i++;
$classitemarray[$i]['name']=$rectemp2['name'];
$classitemarray[$i]['link']='./'.$qmark.'dp-bbsforum-'.$rectemp2['fid'].'.html';
$i++;
$classitemarray[$i]['name']=$rectemp1['name'];
$classitemarray[$i]['link']='./'.$qmark.'dp-bbsforum-'.$rectemp1['fid'].'.html';
}elseif ($rec['type']=='forum') {
$rectemp1=db_fetch_array(db_query('SELECT fid,name FROM '.$tablepre.'forums WHERE fid='.$rec['fup']));
$i++;
$classitemarray[$i]['name']=$rectemp1['name'];
$classitemarray[$i]['link']='./'.$qmark.'dp-bbsforum-'.$rectemp1['fid'].'.html';
}
$i++;
$classitemarray[$i]['name']=$rec['name'];
$classitemarray[$i]['link']='./'.$qmark.'dp-bbsforum-'.$rec['fid'].'.html';
$threadtitle=cutstr($rec['subject'],$title_maxlen);
$threadauthor=$rec['author'];
$threaddate=date($dateformat,$rec['dateline']);
$threadviews=intval($rec['views']);
$forumviewlink=$forumurl.'/viewthread.php?tid='.$tid;
$messagepre='';
}else{
$messagepre= trim($rec['subject'])=='' ? '<br /><br />' : '<br /><br /><strong>'.$rec['subject'].'</strong><br />';
}
$message=bbscms_threadcontent_processmessage($rec['message']);
$attach=bbscms_threadcontent_processattach();
$threadcontent.=$messagepre.$message.$attach;
$authorprev=$rec['author'];
}else{
break;
}
}
}elseif (substr($bbstype,0,2)=='pw') {
$query=db_query('SELECT t.tid,t.author,t.subject,t.postdate AS dateline,hits AS views,tm.content AS message,f.fid,f.fup,f.type,f.name FROM '.$tablepre.'threads t LEFT JOIN '.$tablepre.'tmsgs tm ON tm.tid=t.tid LEFT JOIN '.$tablepre.'forums f ON f.fid=t.fid WHERE t.tid='.$tid.' LIMIT 1');
$rec=db_fetch_array($query);
//Class Links
$classitemarray=array();
$i=-1;
if ($rec['type']=='sub') {
$rectemp1=db_fetch_array(db_query('SELECT fid,fup,name FROM '.$tablepre.'forums WHERE fid='.$rec['fup']));
$rectemp2=db_fetch_array(db_query('SELECT fid,name FROM '.$tablepre.'forums WHERE fid='.$rectemp1['fup']));
$i++;
$classitemarray[$i]['name']=$rectemp2['name'];
$classitemarray[$i]['link']='./'.$qmark.'dp-bbsforum-'.$rectemp2['fid'].'.html';
$i++;
$classitemarray[$i]['name']=$rectemp1['name'];
$classitemarray[$i]['link']='./'.$qmark.'dp-bbsforum-'.$rectemp1['fid'].'.html';
}elseif ($rec['type']=='forum') {
$rectemp1=db_fetch_array(db_query('SELECT fid,name FROM '.$tablepre.'forums WHERE fid='.$rec['fup']));
$i++;
$classitemarray[$i]['name']=$rectemp1['name'];
$classitemarray[$i]['link']='./'.$qmark.'dp-bbsforum-'.$rectemp1['fid'].'.html';
}
$i++;
$classitemarray[$i]['name']=$rec['name'];
$classitemarray[$i]['link']='./'.$qmark.'dp-bbsforum-'.$rec['fid'].'.html';
$threadtitle=cutstr($rec['subject'],$title_maxlen);
$threadauthor=$rec['author'];
$threaddate=date($dateformat,$rec['dateline']);
$threadviews=intval($rec['views']);
$forumviewlink=$forumurl.'/read.php?tid='.$tid;
$message=bbscms_threadcontent_processmessage($rec['message']);
$attach=bbscms_threadcontent_processattach();
$threadcontent=$message.$attach;
if ($ifsmartread) {
$noshowedpid='';
$query=db_query('SELECT pid,author,subject,content FROM '.$tablepre.'posts WHERE tid='.$tid.' ORDER BY postdate ASC');
while ($rec2=db_fetch_array($query)) {
if ($rec2['author']!=$threadauthor) break;
$pid=$rec2['pid'];
$noshowedpid.=' AND pid!='.$pid;
$message=bbscms_threadcontent_processmessage($rec2['content']);
$attach=bbscms_threadcontent_processattach();
$messagepre= trim($rec2['subject'])=='' ? '<br /><br />' : '<br /><br /><strong>'.$rec2['subject'].'</strong><br />';
$threadcontent.=$messagepre.$message.$attach;
}
}
}
//Content Anti Copy
if ($paras['banuncopy']) {
$strlength=mt_rand(4,10);
$classname='';
for ($i=0;$i<$strlength;$i++) {
$classname.=chr(mt_rand(97,122));
}
$threadtitle='<style type="text/css">.'.$classname.' { font-size: 0; color: '.(trim($paras['uncopytextcolor
没有合适的资源?快使用搜索试试~ 我知道了~
[论坛社区]DiY-Page自定制系统 v5.3.1_diy-page_5.zip源码PHP项目源代码下载
共579个文件
gif:280个
php:180个
htm:79个
1.该资源内容由用户上传,如若侵权请联系客服进行举报
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
版权申诉
0 下载量 33 浏览量
2022-03-15
18:54:54
上传
评论
收藏 790KB ZIP 举报
温馨提示
[论坛社区]DiY-Page自定制系统 v5.3.1_diy-page_5.zip源码PHP项目源代码下载[论坛社区]DiY-Page自定制系统 v5.3.1_diy-page_5.zip源码PHP项目源代码下载 1.适合个人搭建网站项目参考 2.适合学生毕业设计搭建网站参考 3.适合小公司搭建网站项目参考
资源推荐
资源详情
资源评论
收起资源包目录
[论坛社区]DiY-Page自定制系统 v5.3.1_diy-page_5.zip源码PHP项目源代码下载 (579个子文件)
main.css 4KB
main.css 4KB
main.css 4KB
main.css 4KB
main.css 4KB
main.css 4KB
main.css 4KB
main.css 3KB
main.css 3KB
main.css 3KB
main.css 3KB
ad3.gif 31KB
awards.gif 14KB
ad4.gif 12KB
ad2.gif 9KB
picnoper.gif 6KB
guide2.gif 6KB
dp_login_avatar.gif 5KB
default_forum.gif 4KB
v41_sb_df_tbg.gif 4KB
top_logo.gif 3KB
logo.gif 3KB
logo.gif 3KB
default_forum.gif 3KB
default_forum.gif 2KB
default_forum.gif 2KB
default_forum.gif 2KB
default_forum.gif 2KB
bigad.gif 2KB
default_forum.gif 2KB
default_forum.gif 2KB
default_forum.gif 2KB
topad.gif 1KB
default_forum.gif 1KB
default_forum.gif 1KB
topbg.gif 1KB
topbg.gif 1KB
topbg.gif 1KB
header_top_bg.gif 1KB
wideframebg.gif 1KB
minibg.gif 1KB
bot.gif 1KB
guideb2.gif 1KB
bot.gif 1KB
bot.gif 1KB
default_thread.gif 1KB
img_add.gif 1KB
box-right.gif 1022B
box-left.gif 1019B
bullet.gif 1004B
float_right.gif 932B
closepop.gif 925B
float_left.gif 923B
minibg.gif 898B
v41_sb_df_tbg.gif 886B
v41_tb_df_body.gif 868B
minibg.gif 854B
v41_sb_df_tbg.gif 851B
v41_tb_df_body.gif 851B
guidebg.gif 844B
wideframebg.gif 840B
minibg.gif 839B
bullet.gif 838B
default_thread.gif 838B
bot.gif 838B
topquick_bg.gif 835B
default_thread.gif 834B
guidebg.gif 832B
guideb1.gif 832B
guidebg.gif 832B
topguide_bg.gif 830B
bullet.gif 829B
bot.gif 829B
bot.gif 829B
bullet.gif 829B
default_thread.gif 829B
bullet.gif 829B
bullet.gif 829B
bot.gif 829B
bot.gif 829B
default_thread.gif 829B
v41_tb_df_tbg.gif 821B
v41_tb_df_tbg.gif 821B
v41_tb_df_tbg.gif 821B
v41_tb_df_tbg.gif 821B
v41_tb_df_tbg.gif 821B
v41_tb_df_tbg.gif 821B
v41_tb_df_tbg.gif 821B
v41_tb_df_tbg.gif 821B
v41_tb_df_tbg.gif 821B
v41_tb_df_tbg.gif 821B
bullet.gif 819B
bot.gif 819B
default_thread.gif 819B
bot.gif 667B
text_paste.gif 628B
new_table_up.gif 624B
move_table_up.gif 619B
move_table_down.gif 617B
new_td_right.gif 617B
共 579 条
- 1
- 2
- 3
- 4
- 5
- 6
资源评论
yxkfw
- 粉丝: 82
- 资源: 2万+
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- 2025计量基础知识考试题库及答案.doc
- 2025金属冶炼(炼钢)安全员考试题库(含答案).pptx
- 2025健康管理师三级专业能力考核试卷及答案.doc
- 2025交管12123驾驶证学法减分题库附含答案.doc
- 建筑工程员工工资表.xls
- 工程部薪酬2018年6月.doc
- 工程施工操作员薪酬管理制度.doc
- 2025教育心理学与德育工作基础知识点大全.doc
- 2025教育心理学与德育工作基础知识点整理总复习资料.doc
- 2025基本公共卫生知识考试题及答案.docx
- 2025基本公共卫生知识题库及答案.docx
- 2025基础知识与规范要求技能大赛题库及答案.docx
- 2025脊柱术后脑脊液漏应急预案考试试题(含答案).docx
- 2025计量基础知识题库及答案.docx
- 2025计算机二级考试全真试题库及答案(通用版).docx
- 2025计算机基础理论信息安全基本知识试题及答案.docx
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功