diff --git a/src/plus/bookfeedback.php b/src/plus/bookfeedback.php deleted file mode 100755 index 5b8bee3..0000000 --- a/src/plus/bookfeedback.php +++ /dev/null @@ -1,316 +0,0 @@ -<?php -require_once(dirname(__FILE__)."/../include/common.inc.php"); -require_once(DEDEINC."/filter.inc.php"); -require_once(DEDEINC."/channelunit.func.php"); -if(!isset($action)) -{ - $action = ''; -} -//兼容旧的JS代码 -if($action == 'good' || $action == 'bad') -{ - if(!empty($aid)) $id = $aid; - require_once(dirname(__FILE__).'/digg_ajax.php'); - exit(); -} - - -function GetOnebook($aid) -{ - global $dsql,$title; - $aid = trim(preg_replace('#[^0-9]#i','',$aid)); - $reArr = array(); - - $nquery = "Select * From `#@__story_books` where bid='$aid' "; - - $arcRow = $dsql->GetOne($nquery); - if(!is_array($arcRow)) { - return $reArr; - } - $reArr = $arcRow; - $reArr['bid'] = $aid; - $reArr['arctitle'] = $arcRow['bookname']; - $title = $arcRow['bookname']; - //$reArr['arcurl'] = GetFileUrl($aid,$arcRow['typeid'],$arcRow['senddate'],$reArr['bookname '],$arcRow['ismake'],$arcRow['arcrank'],$arcRow['namerule'], - //$arcRow['typedir'],$arcRow['money'],$arcRow['filename'],$arcRow['moresite'],$arcRow['siteurl'],$arcRow['sitepath']); - return $reArr; - -} - - -$cfg_formmember = isset($cfg_formmember) ? true : false; -$ischeck = $cfg_feedbackcheck=='Y' ? 0 : 1; -$aid = (isset($aid) && is_numeric($aid)) ? $aid : 0; -$fid = (isset($fid) && is_numeric($fid)) ? $fid : 0; -if(empty($aid) && empty($fid)) -{ - ShowMsg('文档id不能为空!','-1'); - exit(); -} - -include_once(DEDEINC."/memberlogin.class.php"); -$cfg_ml = new MemberLogin(); - -if($action=='goodfb') -{ - AjaxHead(); - $fid = intval($fid); - $dsql->ExecuteNoneQuery("Update `#@__bookfeedback` set good = good+1 where id='$fid' "); - $row = $dsql->GetOne("Select good From `#@__bookfeedback` where id='$fid' "); - echo "<a onclick=\"postBadGood('goodfb',{$aid})\">支持</a>[{$row['good']}]"; - exit(); -} -else if($action=='badfb') -{ - AjaxHead(); - $fid = intval($fid); - $dsql->ExecuteNoneQuery("Update `#@__bookfeedback` set bad = bad+1 where id='$fid' "); - $row = $dsql->GetOne("Select bad From `#@__bookfeedback` where id='$fid' "); - echo "<a onclick=\"postBadGood('badfb',{$aid})\">反对</a>[{$row['bad']}]"; - exit(); -} -//查看评论 -/* -function __ViewFeedback(){ } -*/ -//----------------------------------- -else if($action=='' || $action=='show') -{ - //读取文档信息 - $arcRow = GetOnebook($aid); - if(empty($arcRow['bid'])) - { - ShowMsg('无法查看未知文档的评论!','-1'); - exit(); - } - extract($arcRow, EXTR_SKIP); - include_once(DEDEINC.'/datalistcp.class.php'); - $dlist = new DataListCP(); - $dlist->pageSize = 20; - - if(empty($ftype) || ($ftype!='good' && $ftype!='bad' && $ftype!='feedback')) - { - $ftype = ''; - } - $wquery = $ftype!='' ? " And ftype like '$ftype' " : ''; - - //评论内容列表 - $querystring = "select fb.*,mb.userid,mb.face as mface,mb.spacesta,mb.scores from `#@__bookfeedback` fb - left join `#@__member` mb on mb.mid = fb.mid - where fb.aid='$aid' and fb.ischeck='1' $wquery order by fb.id desc"; - $dlist->SetParameter('aid',$aid); - $dlist->SetParameter('action','show'); - $dlist->SetTemplate($cfg_basedir.$cfg_templets_dir.'/plus/bookfeedback_templet.htm'); - $dlist->SetSource($querystring); - $dlist->Display(); - exit(); -} - -//引用评论 -//------------------------------------ -/* -function __Quote(){ } -*/ -else if($action=='quote') -{ - $row = $dsql->GetOne("Select * from `#@__bookfeedback` where id ='$fid'"); - require_once(DEDEINC.'/dedetemplate.class.php'); - $dtp = new DedeTemplate(); - $dtp->LoadTemplate($cfg_basedir.$cfg_templets_dir.'/plus/bookfeedback_quote.htm'); - $dtp->Display(); - exit(); -} -//发表评论 -//------------------------------------ -/* -function __SendFeedback(){ } -*/ -else if($action=='send') -{ - //读取文档信息 - $arcRow = GetOnebook($aid); - if((empty($arcRow['bid']) || $arcRow['notpost']=='1')&&empty($fid)) - { - ShowMsg('无法对该文档发表评论!','-1'); - exit(); - } - - //是否加验证码重确认 - if(empty($isconfirm)) - { - $isconfirm = ''; - } - if($isconfirm!='yes' && $cfg_feedback_ck=='Y') - { - extract($arcRow, EXTR_SKIP); - require_once(DEDEINC.'/dedetemplate.class.php'); - $dtp = new DedeTemplate(); - $dtp->LoadTemplate($cfg_basedir.$cfg_templets_dir.'/plus/bookfeedback_confirm.htm'); - $dtp->Display(); - exit(); - } - //检查验证码 - if($cfg_feedback_ck=='Y') - { - $validate = isset($validate) ? strtolower(trim($validate)) : ''; - $svali = strtolower(trim(GetCkVdValue())); - if($validate != $svali || $svali=='') - { - ResetVdValue(); - ShowMsg('验证码错误!','-1'); - exit(); - } - } - - //检查用户登录 - if(empty($notuser)) - { - $notuser=0; - } - - //匿名发表评论 - if($notuser==1) - { - $username = $cfg_ml->M_ID > 0 ? '匿名' : '游客'; - } - - //已登录的用户 - else if($cfg_ml->M_ID > 0) - { - $username = $cfg_ml->M_UserName; - } - - //用户身份验证 - else - { - if($username!='' && $pwd!='') - { - $rs = $cfg_ml->CheckUser($username,$pwd); - if($rs==1) - { - $dsql->ExecuteNoneQuery("Update `#@__member` set logintime='".time()."',loginip='".GetIP()."' where mid='{$cfg_ml->M_ID}'; "); - } - else - { - $username = '游客'; - } - } - else - { - $username = '游客'; - } - } - $ip = GetIP(); - $dtime = time(); - - //检查评论间隔时间; - if(!empty($cfg_feedback_time)) - { - //检查最后发表评论时间,如果未登陆判断当前IP最后评论时间 - if($cfg_ml->M_ID > 0) - { - $where = "WHERE `mid` = '$cfg_ml->M_ID'"; - } - else - { - $where = "WHERE `ip` = '$ip'"; - } - $row = $dsql->GetOne("SELECT dtime FROM `#@__bookfeedback` $where ORDER BY `id` DESC "); - if($dtime - $row['dtime'] < $cfg_feedback_time) - { - ResetVdValue(); - ShowMsg('管理员设置了评论间隔时间,请稍等休息一下!','-1'); - exit(); - } - } - - if(empty($face)) - { - $face = 0; - } - $face = intval($face); - extract($arcRow, EXTR_SKIP); - $msg = cn_substrR(TrimMsg($msg),1000); - $username = cn_substrR(HtmlReplace($username,2),20); - if($feedbacktype!='good' && $feedbacktype!='bad') - { - $feedbacktype = 'feedback'; - } - //保存评论内容 - if($comtype == 'comments') - { - $arctitle = addslashes($arcRow['arctitle']); - $arctitle = $arcRow['arctitle']; - if($msg!='') - { - $inquery = "INSERT INTO `#@__bookfeedback`(`aid`,`catid`,`username`,`arctitle`,`ip`,`ischeck`,`dtime`, `mid`,`bad`,`good`,`ftype`,`face`,`msg`) - VALUES ('$aid','$catid','$username','$bookname','$ip','$ischeck','$dtime', '{$cfg_ml->M_ID}','0','0','$feedbacktype','$face','$msg'); "; - $rs = $dsql->ExecuteNoneQuery($inquery); - if(!$rs) - { - echo $dsql->GetError(); - exit(); - } - } - } - //引用回复 - elseif ($comtype == 'reply') - { - $row = $dsql->GetOne("Select * from `#@__bookfeedback` where id ='$fid'"); - $arctitle = $row['arctitle']; - $aid =$row['aid']; - $msg = $quotemsg.$msg; - $msg = HtmlReplace($msg,2); - $inquery = "INSERT INTO `#@__bookfeedback`(`aid`,`typeid`,`username`,`arctitle`,`ip`,`ischeck`,`dtime`,`mid`,`bad`,`good`,`ftype`,`face`,`msg`) - VALUES ('$aid','$typeid','$username','$arctitle','$ip','$ischeck','$dtime','{$cfg_ml->M_ID}','0','0','$feedbacktype','$face','$msg')"; - $dsql->ExecuteNoneQuery($inquery); - } - - - if($cfg_ml->M_ID > 0) - { - #api{{ - if(defined('UC_APPID')) - { - include_once DEDEROOT.'/api/uc.func.php'; - $row = $dsql->GetOne("SELECT `scores`,`userid` FROM `#@__member` WHERE `mid`='".$cfg_ml->M_ID."'"); - uc_credit_note($row['userid'],$cfg_sendfb_scores); - } - #/aip}} - $dsql->ExecuteNoneQuery("Update `#@__member` set scores=scores+{$cfg_sendfb_scores} where mid='{$cfg_ml->M_ID}' "); - } - //统计用户发出的评论 - if($cfg_ml->M_ID > 0) - { - #api{{ - if(defined('UC_APPID')) - { - include_once DEDEROOT.'/api/uc.func.php'; - //推送事件 - $arcRow = GetOnebook($aid); - $feed['icon'] = 'thread'; - $feed['title_template'] = '<b>{username} 在网站发表了评论</b>'; - $feed['title_data'] = array('username' => $cfg_ml->M_UserName); - $feed['body_template'] = '<b>{subject}</b><br>{message}'; - $url = !strstr($arcRow['arcurl'],'http://') ? ($cfg_basehost.$arcRow['arcurl']) : $arcRow['arcurl']; - $feed['body_data'] = array('subject' => "<a href=\"".$url."\">$arcRow[arctitle]</a>", 'message' => cn_substr(strip_tags(preg_replace("/\[.+?\]/is", '', $msg)), 150)); - $feed['images'][] = array('url' => $cfg_basehost.'/images/scores.gif', 'link'=> $cfg_basehost); - uc_feed_note($cfg_ml->M_LoginID,$feed); unset($arcRow); - } - #/aip}} - $row = $dsql->GetOne("SELECT COUNT(*) AS nums FROM `#@__bookfeedback` WHERE `mid`='".$cfg_ml->M_ID."'"); - $dsql->ExecuteNoneQuery("UPDATE `#@__member_tj` SET `feedback`='$row[nums]' WHERE `mid`='".$cfg_ml->M_ID."'"); - } - $_SESSION['sedtime'] = time(); - if(empty($uid) && isset($cmtuser)) $uid = $cmtuser; - $backurl = $cfg_formmember ? "index.php?uid={$uid}&action=viewarchives&aid={$aid}" : "bookfeedback.php?aid=$aid"; - if($ischeck==0) - { - ShowMsg("成功发表评论,但需审核后才会显示你的评论!",$backurl); - }elseif($ischeck==1) - { - ShowMsg("成功发表评论,现在转到评论页面!",$backurl); - } - exit(); -} -?> \ No newline at end of file diff --git a/src/plus/bookfeedback_js.php b/src/plus/bookfeedback_js.php deleted file mode 100755 index f6d6007..0000000 --- a/src/plus/bookfeedback_js.php +++ /dev/null @@ -1,23 +0,0 @@ -<?php -require_once(dirname(__FILE__)."/../include/common.inc.php"); -require_once(DEDEINC."/datalistcp.class.php"); -if(isset($arcID)) -{ - $aid = $arcID; -} -$arcID = $aid = (isset($aid) && is_numeric($aid)) ? $aid : 0; -if($aid==0) -{ - exit(" Request Error! "); -} - -$querystring = "select fb.*,mb.userid,mb.face as mface,mb.spacesta,mb.scores from `#@__bookfeedback` fb - left join `#@__member` mb on mb.mid = fb.mid - where fb.aid='$aid' and fb.ischeck='1' order by fb.id desc"; -$dlist = new DataListCP(); -$dlist->pageSize = 6; -$dlist->SetTemplet(DEDETEMPLATE.'/plus/bookfeedback_templet_js.htm'); -$dlist->SetSource($querystring); -$dlist->display(); - -?> \ No newline at end of file diff --git a/src/templets/plus/bookfeedback_confirm.htm b/src/templets/plus/bookfeedback_confirm.htm deleted file mode 100755 index e1a0111..0000000 --- a/src/templets/plus/bookfeedback_confirm.htm +++ /dev/null @@ -1,184 +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={dede:global.cfg_soft_lang/}" /> -<title>用户评论:{dede:global.title/}</title> -<link href="{dede:global.cfg_templets_skin/}/style/dedecms.css" rel="stylesheet" media="screen" type="text/css" /> -<script language="javascript" type="text/javascript" src="../include/js/dedeajax2.js"></script> -<script language="javascript"> -function postDigg(ftype,aid) -{ - var taget_obj = document.getElementById(ftype+aid); - var saveid = GetCookie('diggid'); - if(saveid != null) - { - var saveids = saveid.split(','); - var hasid = false; - saveid = ''; - j = 1; - for(i=saveids.length-1;i>=0;i--) - { - if(saveids[i]==aid && hasid) continue; - else { - if(saveids[i]==aid && !hasid) hasid = true; - saveid += (saveid=='' ? saveids[i] : ','+saveids[i]); - j++; - if(j==10 && hasid) break; - if(j==9 && !hasid) break; - } - } - if(hasid) { alert("不要重复顶贴!"); return false; } - else saveid += ','+aid; - SetCookie('diggid',saveid,1); - } - else - { - SetCookie('diggid',aid,1); - } - myajax = new DedeAjax(taget_obj,false,false,'','',''); - myajax.SendGet2("bookfeedback.php?action="+ftype+"&aid="+aid); - DedeXHTTP = null; -} -function postBadGood(ftype,fid) -{ - var taget_obj = document.getElementById(ftype+fid); - //document.write("feedback.php?action="+ftype+"&fid="+fid); - //return; - myajax = new DedeAjax(taget_obj,false,false,'','',''); - myajax.SendGet2("bookfeedback.php?aid=1&action="+ftype+"&fid="+fid); - DedeXHTTP = null; -} -</script> -</head> -<body class="commentpage"> -<div class="header"> - <div class="top w960 center"> - - <div class="title"> - <h1> <a href="{dede:global.cfg_basehost/}">{dede:global.cfg_webname/}</a> </h1> - </div> - <!-- /title --> - <div class="welcome"> - <?php if($cfg_ml->M_ID <= 0) { ?> - 您好,欢迎来到本网站,您还没有登陆,请先<a href="<?php echo $cfg_memberurl; ?>/index.php">登陆</a>或者<a href="<?php echo $cfg_memberurl; ?>/index_do.php?fmdo=user&dopost=regnew">注册</a>. - <?php }else{ ?> - - <?php echo $cfg_ml->M_LoginID; ?>,欢迎您的登陆。 - <a href="<?php echo $cfg_memberurl; ?>/index.php">会员中心</a> | - <a href="<?php echo $cfg_memberurl; ?>/edit_fullinfo.php">我的资料</a> | - <a href="<?php echo $myurl;?>">我的空间</a> | - <a href="<?php echo $cfg_memberurl; ?>/index_do.php?fmdo=login&dopost=exit">退出登录</a> - <?php - } - ?> - </div> - - </div> - <!-- /top --> - - </div><!-- /nav --> -</div><!-- /header --> - -<div class="w960 clear center mt1 cmt-box"> - <div class="sp-title"> - <h2>评论:<a href='{dede:global.arcurl/}' >{dede:global.title/}</a></h2> - - </div> - <div> - <dl class="tbox"> - <dt> - <strong>摘要:</strong> - </dt> - <dd> - <div class="dede_comment"> - - <div class="decmt-box"> - <span class="date">发布时间:{dede:global.pubdate function="MyDate('Y-m-d H:i',@me)" /}</span> - </div><!-- /decmt-title --> - <div class="decmt-act"> - <span>总积分[{dede:global.scores/}]</span> - <span id='good{dede:global.id/}'><a href="#" onclick="postDigg('good',{dede:global.id/})">好评</a>[{dede:field.goodpost/}]</span> - <span id='bad{dede:global.id/}'><a href="#" onclick="postDigg('bad',{dede:global.id/})">差评</a>[{dede:field.badpost/}]</span> - - <span><a href="stow.php?aid={dede:global.id/}">收藏</a></span> - </div><!-- /decmt-act --> - <div class="decmt-content"> - {dede:global.description/}... - </div> - </div><!-- /dede_comment --> - </dd> - </dl> - </div> - - <div class="mt1"> - <dl class="tbox"> - <dt><strong>发表评论</strong></dt> - <dd> - <div class="dede_comment_post"> - <form action="bookfeedback.php" method="post" name="feedback"> - <input type="hidden" name="action" value="send" /> - <input type="hidden" name="aid" value="<?php echo $aid; ?>" /> - - <input type="hidden" name="isconfirm" value="yes" /> - <div class="dcmp-mood"> - <strong>表情:</strong> - <ul> - <li><input type="radio" name='face' value='6' checked="1" /><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-6.gif" /></li> - <li><input type="radio" name='face' value='4'/><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-4.gif" /></li> - <li><input type="radio" name='face' value='3'/><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-3.gif" /></li> - <li><input type="radio" name='face' value='5'/><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-5.gif" /></li> - <li><input type="radio" name='face' value='2'/><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-2.gif" /></li> - <li><input type="radio" name='face' value='1'/><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-1.gif" /></li> - <li><input type="radio" name='face' value='7'/><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-7.gif" /></li> - </ul> - </div><!-- /dcmp-mood --> - <div class="dcmp-stand"> - <strong>评价:</strong> - <input type="radio" name="feedbacktype" checked="1" value="feedback" id="dcmp-stand-neu" /><label for="dcmp-stand-neu"><img src="{dede:global.cfg_templets_skin/}/images/cmt-neu.gif" />中立</label> - <input type="radio" name="feedbacktype" value="good" id="dcmp-stand-good" /><label for="dcmp-stand-good"><img src="{dede:global.cfg_templets_skin/}/images/cmt-good.gif" />好评</label> - <input type="radio" name="feedbacktype" value="bad" id="dcmp-stand-bad" /><label for="dcmp-stand-bad"><img src="{dede:global.cfg_templets_skin/}/images/cmt-bad.gif" />差评</label> - </div><!-- /dcmp-stand --> - <div class="dcmp-content"> - <textarea cols="60" name="msg" rows="5" class="ipt-txt"></textarea> - </div><!-- /dcmp-content --> - <div class="dcmp-title"> - - <small>请自觉遵守互联网相关的政策法规,严禁发布色情、暴力、反动的言论。</small> - </div><!-- /dcmp-title --> - <div class="dcmp-post"><!--未登陆--> - <div class="dcmp-userinfo"> -用户名: - <?php if($cfg_ml->M_ID <= 0) { ?> - <input name="username" type="text" id="username" size="10" class="nb" /> - (<a href="../member/index_do.php?fmdo=user&dopost=regnew" target="_blank"><u>注册新用户</u></a>) - 密码: - <input name="pwd" type="password" id="pwd" size="10"class="nb" /> - - <?php - }else{ echo $cfg_ml->M_LoginID." "; } - ?> - <input name="notuser" type="checkbox" id="notuser" value="1" /> - 匿名评论 - <?php if($cfg_feedback_ck=='Y') { ?> - 验证码:<input name="validate" type="text" id="validate" size="10" style="height:18px;width:60px;margin-right:6px;text-transform: uppercase;" class="nb" /> - <img src='../include/vdimgck.php' /> - - <?php } ?> - <button type="button" onClick='javascript:if(document.feedback.msg.value!="") document.feedback.submit(); else alert("评论内容不能为空!");' class="btn-2">发表评论</button> - - </div><!-- /dcmp-submit --> - </div><!-- /dcmp-post --> - </form> - </div><!-- /dede_comment_post --> - - </dd> - </dl> - </div> -</div> - -{dede:include filename="../default/footer.htm"/} -<!-- /footer --> - - -</body> -</html> diff --git a/src/templets/plus/bookfeedback_quote.htm b/src/templets/plus/bookfeedback_quote.htm deleted file mode 100755 index efcb549..0000000 --- a/src/templets/plus/bookfeedback_quote.htm +++ /dev/null @@ -1,134 +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={dede:global.cfg_soft_lang/}" /> -<title>用户评论:<?php echo $row['arctitle'];?></title> -<link href="{dede:global.cfg_templets_skin/}/style/dedecms.css" rel="stylesheet" media="screen" type="text/css" /> -</head> -<body class="commentpage"> -<div class="header"> - <div class="top w960 center"> - <div class="title"> - <h1> <a href="{dede:global.cfg_basehost/}">{dede:global.cfg_webname/}</a> </h1> - - </div> - <!-- /title --> - <div class="welcome"> - <?php if($cfg_ml->M_ID <= 0) { ?> - 您好,欢迎来到本网站,您还没有登陆,请先<a href="<?php echo $cfg_memberurl; ?>/index.php">登陆</a>或者<a href="<?php echo $cfg_memberurl; ?>/index_do.php?fmdo=user&dopost=regnew">注册</a>. - <?php }else{ ?> - <?php echo $cfg_ml->M_LoginID; ?>,欢迎您的登陆。 - <a href="<?php echo $cfg_memberurl; ?>/index.php">会员中心</a> | - <a href="<?php echo $cfg_memberurl; ?>/edit_fullinfo.php">我的资料</a> | - <a href="<?php echo $myurl;?>">我的空间</a> | - <a href="<?php echo $cfg_memberurl; ?>/index_do.php?fmdo=login&dopost=exit">退出登录</a> - - <?php - } - ?> - </div> - <!-- /banner --> - </div> - <!-- /top --> - - </div><!-- /nav --> -</div><!-- /header --> - -<div class="w960 clear center mt1 cmt-box"> - <div class="sp-title"> - - <h2>评论:<?php echo $row['arctitle'];?></h2> - </div> - <div> - <dl class="tbox"> - <dt> - <strong>评论说明:</strong> - </dt> - <dd> - - <div class="dede_comment"> - <div class="decmt-box"> - 选择不同的评价类型会影响文章的积分,心情不影响积分,如果你不想长篇大论,只需点击“好评/差评”图标,同样可以为文章增加或减少积分。<br /> - 选择“匿名评论”后,不管是否登陆都不显示你的空间链接,请自觉遵守互联网相关的政策法规,严禁发布色情、暴力、反动的言论。</div> - </div><!-- /dede_comment --> - </dd> - </dl> - </div> - - <div class="mt1"> - <dl class="tbox"> - <dt><strong>发表评论</strong></dt> - <dd> - <div class="dede_comment_post"> - <form action="bookfeedback.php" method="post" name="feedback"> - <input type="hidden" name="action" value="send" /> - <input type="hidden" name="comtype" value="reply" /> - - <input type="hidden" name="fid" value="<?php echo $row['id']; ?>" /> - <input type="hidden" name="isconfirm" value="yes" /> - <input type="hidden" name="typeid" value="<?php echo $row['typeid'];?>" /> - <div class="dcmp-mood"> - <strong>表情:</strong> - <ul> - <li><input type="radio" name='face' value='6' checked="1" /><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-6.gif" /></li> - <li><input type="radio" name='face' value='4'/><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-4.gif" /></li> - <li><input type="radio" name='face' value='3'/><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-3.gif" /></li> - <li><input type="radio" name='face' value='5'/><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-5.gif" /></li> - <li><input type="radio" name='face' value='2'/><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-2.gif" /></li> - <li><input type="radio" name='face' value='1'/><img src="{dede:global.cfg_templets_skin/}/mages/mood/ico-mood-1.gif" /></li> - <li><input type="radio" name='face' value='7'/><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-7.gif" /></li> - </ul> - </div><!-- /dcmp-mood --> - <div class="dcmp-stand"> - <strong>评价:</strong> - - <input type="radio" name="feedbacktype" checked="1" value="feedback" id="dcmp-stand-neu" /><label for="dcmp-stand-neu"><img src="{dede:global.cfg_templets_skin/}/images/cmt-neu.gif" />中立</label> - <input type="radio" name="feedbacktype" value="good" id="dcmp-stand-good" /><label for="dcmp-stand-good"><img src="{dede:global.cfg_templets_skin/}/images/cmt-good.gif" />好评</label> - <input type="radio" name="feedbacktype" value="bad" id="dcmp-stand-bad" /><label for="dcmp-stand-bad"><img src="{dede:global.cfg_templets_skin/}/images/cmt-bad.gif" />差评</label> - </div><!-- /dcmp-stand --> - <div class="dcmp-content"> - <input type="hidden" name="quotemsg" value="{quote}<?php echo '{title}'.$row['username'].' 的原帖:{/title}{content}'.$row['msg'].'{/content}';?>{/quote}" /> - <textarea cols="60" name="msg" rows="5" class="ipt-txt"></textarea> - - </div><!-- /dcmp-content --> - <div class="dcmp-title"> - <small>请自觉遵守互联网相关的政策法规,严禁发布色情、暴力、反动的言论。</small> - </div><!-- /dcmp-title --> - <div class="dcmp-post"><!--未登陆--> - <div class="dcmp-userinfo"> -用户名: - <?php if($cfg_ml->M_ID <= 0) { ?> - <input name="username" type="text" id="username" size="10" class="nb" /> - - (<a href="../member/index_do.php?fmdo=user&dopost=regnew" target="_blank"><u>注册新用户</u></a>) - 密码: - <input name="pwd" type="password" id="pwd" size="10"class="nb" /> - <?php - }else{ echo $cfg_ml->M_LoginID." "; } - ?> - <input name="notuser" type="checkbox" id="notuser" value="1" /> - 匿名评论 - <?php if($cfg_feedback_ck=='Y') { ?> - 验证码:<input name="validate" type="text" id="validate" size="10" style="height:18px;width:60px;margin-right:6px;text-transform: uppercase;" class="nb" /> - <img src='../include/vdimgck.php' /> - - <?php } ?> - <button type="button" onClick='javascript:if(document.feedback.msg.value!="") document.feedback.submit(); else alert("评论内容不能为空!");'>发表评论</button> - </div><!-- /dcmp-submit --> - </div><!-- /dcmp-post --> - </form> - </div><!-- /dede_comment_post --> - - </dd> - - </dl> - </div> -</div> - - -{dede:include filename="../default/footer.htm"/} -<!-- /footer --> - - -</body> -</html> diff --git a/src/templets/plus/bookfeedback_templet.htm b/src/templets/plus/bookfeedback_templet.htm deleted file mode 100755 index 6de8ced..0000000 --- a/src/templets/plus/bookfeedback_templet.htm +++ /dev/null @@ -1,210 +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={dede:global.cfg_soft_lang/}" /> -<title>用户评论:{dede:global.title/}</title> -<link href="{dede:global.cfg_templets_skin/}/style/dedecms.css" rel="stylesheet" media="screen" type="text/css" /> -<script language="javascript" type="text/javascript" src="../include/js/dedeajax2.js"></script> -<script language="javascript"> -function postBadGood(ftype,fid) -{ - var taget_obj = document.getElementById(ftype+fid); - var saveid = GetCookie('badgoodid'); - if(saveid != null) - { - var saveids = saveid.split(','); - var hasid = false; - saveid = ''; - j = 1; - for(i=saveids.length-1;i>=0;i--) - { - if(saveids[i]==fid && hasid) continue; - else { - if(saveids[i]==fid && !hasid) hasid = true; - saveid += (saveid=='' ? saveids[i] : ','+saveids[i]); - j++; - if(j==10 && hasid) break; - if(j==9 && !hasid) break; - } - } - if(hasid) { alert('您刚才已表决过了喔!'); return false; } - else saveid += ','+fid; - SetCookie('badgoodid',saveid,1); - } - else - { - SetCookie('badgoodid',fid,1); - } - //document.write("feedback.php?action="+ftype+"&fid="+fid); - //return; - myajax = new DedeAjax(taget_obj,false,false,'','',''); - myajax.SendGet2("bookfeedback.php?aid={dede:global.aid/}&action="+ftype+"&fid="+fid); - DedeXHTTP = null; -} -</script> -<body class="commentpage"> - -<div class="header"> - <div class="top w960 center"> - - <div class="title"> - <h1> <a href="{dede:global.cfg_basehost/}/">{dede:global.cfg_webname/}</a> </h1> - </div> - <!-- /title --> - <div class="welcome"> - <?php if($cfg_ml->M_ID <= 0) { ?> - 您好,欢迎来到本网站,您还没有登陆,请先<a href="<?php echo $cfg_memberurl; ?>/index.php">登陆</a>或者<a href="<?php echo $cfg_memberurl; ?>/index_do.php?fmdo=user&dopost=regnew">注册</a>. - <?php }else{ ?> - - <?php echo $cfg_ml->M_LoginID; ?>,欢迎您的登陆。 - <a href="<?php echo $cfg_memberurl; ?>/index.php">会员中心</a> | - <a href="<?php echo $cfg_memberurl; ?>/edit_fullinfo.php">我的资料</a> | - <a href="<?php echo $cfg_memberurl; ?>/index.php?uid=<?php echo urlencode($cfg_ml->M_LoginID);?>">我的空间</a> | - <a href="<?php echo $cfg_memberurl; ?>/index_do.php?fmdo=login&dopost=exit">退出登录</a> - <?php - } - ?> - </div> - - <!-- /banner --> - </div> - <!-- /top --> - - </div><!-- /nav --> -</div><!-- /header --> -<div class="w960 clear center mt1 cmt-box"> - <div class="sp-title"> - <h2>评论:<a href='/book/book.php?bid={dede:global.bid/}'>{dede:global.title/}</a></h2> - - </div> - <div> - <dl class="tbox"> - <dt> - <strong>评论列表(网友评论仅供网友表达个人看法,并不表明本站同意其观点或证实其描述)</strong> - <span class="label"> -<a href='bookfeedback.php?aid={dede:global.aid/}&ftype=good' <?php if($ftype=='good') echo "class='thisclass'"; ?>>只看好评</a> -<a href='bookfeedback.php?aid={dede:global.aid/}&ftype=bad' <?php if($ftype=='bad') echo "class='thisclass'"; ?>>只看差评</a> - -<a href='bookfeedback.php?aid={dede:global.aid/}&ftype=feedback' <?php if($ftype=='feedback') echo "class='thisclass'"; ?>>只看中立</a> -<a href='bookfeedback.php?aid={dede:global.aid/}' <?php if($ftype=='') echo "class='thisclass'"; ?>>全部评论</a> - </span> - </dt> - <dd> - <div class="dede_comment"> -{dede:datalist} -<?php - if($fields['userid']!='') $spaceurl = $cfg_basehost.'/member/index.php?uid='.$fields['userid']; - else $spaceurl = "#"; - if($fields['username']=='匿名') $spaceurl = "#"; - $fields['bgimg'] = 'cmt-neu.gif'; - $fields['ftypetitle'] = '该用户表示中立'; - if($fields['ftype']=='bad') { - $fields['bgimg'] = 'cmt-bad.gif'; - $fields['ftypetitle'] = '该用户表示差评'; - } - else if($fields['ftype']=='good') { - $fields['bgimg'] = 'cmt-good.gif'; - $fields['ftypetitle'] = '该用户表示好评'; - } -?> - <div class="decmt-box"> - <div class="decmt-title"> - - <span class="moodico"><img src="{dede:global.cfg_templets_skin/}/images/mood/<?php if($fields['face']>0) echo "ico-mood-{$fields['face']}.gif"; ?>" /> </span> - <span class="username"> {dede:field.username/}</span> - <span class="date"> 于 {dede:field.dtime function="MyDate('m-d H:i',@me)" /}</span>说到</div><!-- /decmt-title --> - <div class="decmt-act"> - <span id='goodfb{dede:field.id/}'><a href="#" onclick="postBadGood('goodfb',{dede:field.id/})">支持</a>[{dede:field.good/}]</span> - <span id='badfb{dede:field.id/}'><a href="#" onclick="postBadGood('badfb',{dede:field.id/})">反对</a>[{dede:field.bad/}]</span> - <span><a href="bookfeedback.php?fid={dede:field.id/}&action=quote">引用</a></span> - </div><!-- /decmt-act --> - <div class="decmt-content"> - {dede:field.msg function="Quote_replace(@me)"/} - <img src="{dede:global.cfg_templets_skin/}/images/{dede:field.bgimg/}" /> - </div><!-- /decmt-content --> - </div><!-- /decmt-box --> - -{/dede:datalist} {dede:pagelist listitem="info,index,end,pre,next,pageno" listsize="5"/} </div><!-- /dede_comment --> - </dd> - </dl> - </div> - - <div class="mt1"> - <dl class="tbox"> - <dt> - <strong>发表评论</strong> - - </dt> - <dd> - <div class="dede_comment_post"> - <form action="bookfeedback.php" method="post" name="feedback"> - <input type="hidden" name="action" value="send" /> - <input type="hidden" name="comtype" value="comments"> - <input type="hidden" name="aid" value="<?php echo $aid; ?>" /> - <input type="hidden" name="isconfirm" value="yes" /> - <div class="dcmp-title"> - - <small>请自觉遵守互联网相关的政策法规,严禁发布色情、暴力、反动的言论。</small> - </div><!-- /dcmp-title --> - <div class="dcmp-stand"> - <strong>评价:</strong> - <input type="radio" name="feedbacktype" checked="1" value="feedback" id="dcmp-stand-neu" /><label for="dcmp-stand-neu"><img src="{dede:global.cfg_templets_skin/}/images/cmt-neu.gif" />中立</label> - <input type="radio" name="feedbacktype" value="good" id="dcmp-stand-good" /><label for="dcmp-stand-good"><img src="{dede:global.cfg_templets_skin/}/images/cmt-good.gif" />好评</label> - <input type="radio" name="feedbacktype" value="bad" id="dcmp-stand-bad" /><label for="dcmp-stand-bad"><img src="{dede:global.cfg_templets_skin/}/images/cmt-bad.gif" />差评</label> - - </div><!-- /dcmp-stand --> - <div class="dcmp-content"> - <textarea cols="60" name="msg" rows="5" class="ipt-txt"></textarea> - </div><!-- /dcmp-content --> - - <div class="dcmp-mood"> - <strong>表情:</strong> - <ul> - - <li><input type="radio" name='face' value='6' checked="1" /><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-6.gif" /></li> - <li><input type="radio" name='face' value='4'/><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-4.gif" /></li> - <li><input type="radio" name='face' value='3'/><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-3.gif" /></li> - <li><input type="radio" name='face' value='5'/><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-5.gif" /></li> - <li><input type="radio" name='face' value='2'/><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-2.gif" /></li> - <li><input type="radio" name='face' value='1'/><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-1.gif" /></li> - <li><input type="radio" name='face' value='7'/><img src="{dede:global.cfg_templets_skin/}/images/mood/ico-mood-7.gif" /></li> - </ul> - </div><!-- /dcmp-mood --> - - <div class="dcmp-post"><!--未登陆--> - <div class="dcmp-userinfo"> -用户名: - <?php if($cfg_ml->M_ID <= 0) { ?> - <input name="username" type="text" id="username" size="10" class="nb" /> - (<a href="../member/index_do.php?fmdo=user&dopost=regnew" target="_blank"><u>注册新用户</u></a>) - 密码: - <input name="pwd" type="password" id="pwd" size="10"class="nb" /> - <?php - }else{ echo $cfg_ml->M_LoginID." "; } - ?> - <input name="notuser" type="checkbox" id="notuser" value="1" /> - - 匿名评论 - <?php if($cfg_feedback_ck=='Y') { ?> - 验证码:<input name="validate" type="text" id="validate" size="10" style="height:18px;width:60px;margin-right:6px;text-transform: uppercase;" class="nb" /> - <img src='../include/vdimgck.php'/> - - <?php } ?> - <button type="submit" class="btn-2">发表评论</button> - </div><!-- /dcmp-submit --> - </div><!-- /dcmp-post --> - - </form> - </div><!-- /dede_comment_post --> - - </dd> - </dl> - </div> -</div> - - -{dede:include filename="../default/footer.htm"/} -<!-- /footer --> -</body> - -</html> diff --git a/src/templets/plus/bookfeedback_templet_js.htm b/src/templets/plus/bookfeedback_templet_js.htm deleted file mode 100755 index a98f523..0000000 --- a/src/templets/plus/bookfeedback_templet_js.htm +++ /dev/null @@ -1,39 +0,0 @@ -<?php -require_once(DEDEINC."/common.func.php"); -?> -{dede:config pagesize='5'/} -{dede:datalist} -<?php - if($fields['userid']!='') $spaceurl = $cfg_basehost.'/member/index.php?uid='.$fields['userid']; - else $spaceurl = "#"; - if($fields['username']=='匿名') $spaceurl = "#"; - $fields['bgimg'] = 'cmt-neu.gif'; - $fields['ftypetitle'] = '该用户表示中立'; - if($fields['ftype']=='bad') { - $fields['bgimg'] = 'cmt-bad.gif'; - $fields['ftypetitle'] = '该用户表示差评'; - } - else if($fields['ftype']=='good') { - $fields['bgimg'] = 'cmt-good.gif'; - $fields['ftypetitle'] = '该用户表示好评'; - } -?> -document.write("<div class='decmt-box'>"); -document.write("<div class='decmt-title'>"); -document.write("<span class='moodico'><img src='{dede:global.cfg_templeturl/}/images/mood/ico-mood-<?php if($fields['face']>0) echo $fields['face'];?>.gif'/></span>"); -document.write("<span class='username'><a href='<?php echo $spaceurl;?>'>{dede:field.username/}</a></span>"); -document.write("<span class='date'>{dede:field.dtime function=GetDateMk(@me)/}</span>"); -document.write("<span>发表</span>"); -document.write("</div>"); -document.write("<div class='decmt-act'>"); -document.write("<span id='goodfb{dede:field.id/}'><a href=#goodfb{dede:field.id/} onclick=postBadGood('goodfb',{dede:field.id/})>支持</a>[{dede:field.good/}]</span>"); -document.write("<span id='badfb{dede:field.id/}'><a href=#badfb{dede:field.id/} onclick=postBadGood('badfb',{dede:field.id/})>反对</a>[{dede:field.bad/}]</span>"); -document.write("<span><a href='/plus/bookfeedback.php?fid={dede:field.id/}&action=quote'>引用</a></span>"); -document.write("</div>"); -document.write("<div class='decmt-content'>{dede:field.msg function=jstrim(@me,100)/}<img src='{dede:global.cfg_templeturl/}/images/{dede:field.bgimg/}' alt='{dede:field.ftypetitle/}' />"); -document.write("</div>"); -document.write("</div>"); -{/dede:datalist} - - -