本帖最后由 wade8 于 2009-8-18 14:45 编辑
冰凉秘密插件按你说的方法改了还是不能解决回复跳转的问题。原本已经有那段代码了
function reply_reload(cid, result) {
$("comment_message").value = "";
window.location.reload();
}
--------------------------------------------------------------------
以下是秘密的原代码:
<!--{eval $_TPL['titles'] = array($mimi['title'], '晒秘密');}-->
<!--{template header}-->
<!--{template mimi/view/mimi_header}-->
<script type="text/javascript">
var arrids = [$str_ids];
var total_score = {$mimi[score]} ;
function closeSide() {
if ($('div_main').className == 'side_right') {
$('div_main').className = 'side_right side_right_close';
$('a_showSide').innerHTML = '« 打开侧边栏';
$('a_showSide').className = 'openside';
} else {
$('div_main').className = 'side_right';
$('a_showSide').innerHTML = '» 关闭侧边栏';
$('a_showSide').className = '';
}
$('a_showSide').blur();
}
function show_trace(id) {
ajaxget('do.php?ac=ajax&op=trace&blogid='+$id, 'trace_ul');
return false;
}
function show_trace_all() {
ajaxget('do.php?ac=ajax&op=traceall&blogid='+$id+'&ajaxdiv=trace_div', 'trace_div');
return false;
}
function reply_reload(cid, result) {
$("comment_message").value = "";
window.location.reload();
}
function sum_score() {
var has_score = 0;
for( id in arrids ) {
has_score += parseInt( $("text_score_" + arrids[id]).value );
}
return has_score;
}
function show_self(id) {
$("alt_msg_" + id ).innerHTML = "不能给自己加分";
$("alt_msg_" + id ).style.display = 'block';
}
function hide_it(id) {
$("alt_msg_" + id ).style.display = 'none';
}
function show_score(id) {
var has_score = sum_score();
var leave_score = {$mimi[score]} - has_score;
var color = leave_score < 0 ? 'red' : 'blue';
$("alt_msg_" + id ).innerHTML = "悬赏积分: {$mimi[score]} <br />已经给分: " + has_score + "<br />还剩: <font color="+color+">" + leave_score + "</font>";
$("alt_msg_" + id ).style.display = 'block';
}
function checkForm() {
var has_score = sum_score();
var leave_score = {$mimi[score]} - has_score;
if( leave_score > 0 ) {
alert("您的悬赏分未分配完, 请重新分配");
return false;
} else if( leave_score < 0 ) {
alert("您给出的分值之和比您的悬赏分还多,请重新分配");
return false;
}
if( !confirm("确定结束吗?结束后不能再次修改 ") ) {
return false;
}
return true;
}
</script>
<div class=div_layout>
<div class="h_status">
</div>
<div class=left>
<div>
<div overflow="hidden" height="407" width="560">
<div class="side_right">
<div class="wide">
<div class="post_list a_list">
<table width="570" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="31"><div align="center"><strong>以下是有人冒充$mimi[title]发布的秘密!</strong></div></td>
</tr>
<tr>
<td height="1" background="mimi/css/bg_line.gif"></td>
</tr>
<tr>
<td height="23"><div align="center">被冒充者:<b style="color:red;">$mimi[title]</b>
<span class="pipe">|</span>
一共有$mimi[view_count] 次阅读 <span class="pipe">|</span>
性别: <a href="mimi.php?do=mimi&type=$mimi['typeid']">{$gEumsType[$mimi[typeid]]}</a></div></td>
</tr>
<tr>
<td><br><br>$mimi[content]<br><br></td>
</tr>
<tr>
<td height="1" background="mimi/css/bg_line.gif"></td>
</tr>
<tr>
<td><div align="right">
发布时间: <!--{date('Y-m-d H:i',$mimi[dateline])}--> <!--{if $_SGLOBAL[supe_uid] == $mimi['uid']}-->
<a href="mimi.php?do=mimi&ac=post&id=$id&op=edit">编辑信息</a><span class="pipe">|</span>
<a href="mimi.php?do=mimi&ac=cp&id=$id&op=delete" id="blog_delete_$blog[blogid]" onclick="ajaxmenu(event, this.id, 99999)">删除</a>
<!--{elseif $_SGLOBAL[supe_uid] == ADMIN_ID }-->
<a href="mimi.php?do=mimi&ac=cp&id=$id&op=delete" id="blog_delete_$blog[blogid]" onclick="ajaxmenu(event, this.id, 99999)">删除</a>
<!--{/if}--> </div> </td>
</tr>
</table>
</div>
</div>
</div>
</div>
</div>
<div><br><br><br>
<h2>评论</h2><br>
<div class=mimi>
<form action="mimi.php?do=mimi&ac=cp&op=finish" onsubmit="return checkForm()" method="post">
<!--{loop $reply $value}-->
<div style="color:#999999; padding:4px; margin:0px; text-align:left; border:1px dotted #ccc">
<table width="560" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="100" rowspan="2"><div align="center">
<div class="avatar48" align="left"><a href="space.php?uid=$value[uid]"><!--{avatar($value[uid],small)}--></a></div><a href="space.php?uid=$value[uid]" id="author_$value[id]">$value[username]</a>
</td>
<td height="57">$value[content]</td>
</tr>
<tr>
<td> <div align="right">
评论时间: <!--{date('Y-m-d H:i',$value[dateline])}--> <span class="pipe">|</span>
<!--{if $value[uid]==$_SGLOBAL[supe_uid] || $_SGLOBAL[supe_uid] == ADMIN_ID }-->
<a href="mimi.php?do=mimi&ac=cp&op=replydelete&mimi_id={$mimi[id]}&id=$value[id]" id="c_$value[id]_delete" onclick="return confirm('确定删除吗?')">删除</a>
<!--{/if}--></div></td>
</tr>
</table>
</div> <br>
<!--{/loop}-->
<input type="hidden" name="mimi_id" id="mimi_id" value="$mimi[id]" />
<input type="hidden" name="theurl" value="$theurl" />
</form>
<br>
<form id="commentform" name="commentform" action="mimi.php?do=mimi&ac=cp&op=reply" method="post" class="quickpost">
<table cellpadding="0" cellspacing="0">
<tr>
<td>
<textarea id="comment_message" name="content" rows="5" onkeydown="ctrlEnter(event, 'reply_submit_btn');"></textarea></td>
</tr>
<tr>
<td>
<input type="hidden" name="refer" value="$theurl" />
<input type="hidden" name="mimi_id" value="$mimi_id">
<input type="hidden" name="mimi_title" value="$mimi[title]" />
<input type="hidden" name="mimi_uid" value="$mimi[uid]" />
<input type="button" id="reply_submit_btn" name="reply_submit_btn" class="submit" value="回复" onclick="ajaxpost('commentform', 'comment_status', 'reply_reload')" />
<span id="comment_status"></span>
</td>
</tr>
</table>
</form>
</div>
</div>
</div>
<div id="wajinbar">
</div>
</div>
<!--{template footer}--> |