楼主你帮我看下怎么改 www.myspar.net
谢谢了
这是我的 viewthread.htm
<SCRIPT language=JavaScript1.2>
function html_trans(str) {
str = str.replace(/\r/g,"");
str = str.replace(/on(load|click|dbclick|mouseover|mousedown|mouseup)="[^"]+"/ig,"");
str = str.replace(/<script[^>]*?>([\w\W]*?)<\/script>/ig,"");
str = str.replace(/<a[^>]+href="([^"]+)"[^>]*>(.*?)<\/a>/ig,"\n$2\n");
str = str.replace(/<font[^>]+color=([^ >]+)[^>]*>(.*?)<\/font>/ig,"\n[color=$1]$2\n");
str = str.replace(/<img[^>]+src="([^"]+)"[^>]*>/ig,"\n\n");
str = str.replace(/<([\/]?)b>/ig,"[$1b]");
str = str.replace(/<([\/]?)strong>/ig,"[$1b]");
str = str.replace(/<([\/]?)u>/ig,"[$1u]");
str = str.replace(/<([\/]?)i>/ig,"[$1i]");
str = str.replace(/ /g," ");
str = str.replace(/&/g,"&");
str = str.replace(/"/g,"\"");
str = str.replace(/</g,"<");
str = str.replace(/>/g,">");
str = str.replace(/<br>/ig,"\n");
str = str.replace(/<[^>]*?>/g,"");
str = str.replace(/\[url=([^\]]+)\]\n(\[img\]\1\[\/img\])\n\[\/url\]/g,"$2");
str = str.replace(/\n+/g,"\n");
return str;
}
function trans(){
var str = "";
rtf.focus();
rtf.document.body.innerHTML = "";
rtf.document.execCommand("paste");
str = rtf.document.body.innerHTML;
if(str.length == 0) {
alert("管理员友情提醒:剪切版不存在超文本数据!");
return "";
}
return html_trans(str);
}
</SCRIPT>
{template header}
<table cellspacing="0" cellpadding="0" border="0" width="{TABLEWIDTH}" align="center" style="table-layout: fixed">
<tr><td class="nav" width="85%" align="left" nowrap> <a href="index.php">$bbname</a> $navigation</td>
<td align="right" width="15%"><a href="rss.php?fid=$fid&auth=$rssauth" target="_blank"><img src="images/common/xml.gif" border="0" align="absmiddle" alt="{lang rss_subscribe_this}"></a>
<a href="#bottom"><img src="{IMGDIR}/arrow_dw.gif" border="0" align="absmiddle"></a></td>
</tr></table><br>
<!--{if !empty($advlist['text'])}--><table cellspacing="{INNERBORDERWIDTH}" cellpadding="{TABLESPACE}" width="{TABLEWIDTH}" align="center" class="tableborder">$advlist[text]</table><br><!--{/if}-->
<!--{if $polloptions}-->
{template viewthread_poll}
<!--{/if}-->
<!--{if $newpmexists}-->
{template pmprompt}
<!--{/if}-->
<table width="{TABLEWIDTH}" cellspacing="0" cellpadding="0" align="center">
<tr><td valign="bottom">
<table cellspacing="{INNERBORDERWIDTH}" cellpadding="2" class="tableborder">
<tr class="smalltxt">
<!--{if $highlightstatus}--><td class="altbg2"><a href="viewthread.php?tid=$tid&page=$page" style="font-weight: normal">{lang disable_highlight}</a></td><!--{/if}-->
<td class="altbg2"><a href="redirect.php?fid=$fid&tid=$tid&goto=nextoldset" style="font-weight: normal">{lang last_thread}</a></td>
<td class="altbg2"><a href="redirect.php?fid=$fid&tid=$tid&goto=nextnewset" style="font-weight: normal">{lang next_thread}</a></td>
</tr></table>
$multipage</td><td align="right" valign="bottom">
<!--{if $allowpost || !$discuz_uid}--> <a href="post.php?action=newthread&fid=$fid&extra=$extra"><img src="{IMGDIR}/newtopic.gif" border="0"></a><!--{/if}-->
<!--{if $allowpostpoll || !$discuz_uid}--> <a href="post.php?action=newthread&fid=$fid&extra=$extra&poll=yes"><img src="{IMGDIR}/poll.gif" border="0"></a><!--{/if}-->
<!--{if ($allowpost || !$discuz_uid) && $allowposttrade}--> <a href="post.php?action=newthread&fid=$fid&extra=$extra&trade=yes"><img src="{IMGDIR}/newtrade.gif" border="0"></a><!--{/if}-->
<!--{if $allowpostreply || !$discuz_uid}--> <a href="post.php?action=reply&fid=$fid&tid=$tid&extra=$extra"><img src="{IMGDIR}/reply.gif" border="0"></a><!--{/if}-->
</td></tr></table>
<script language="JavaScript">
function fastreply(subject) {
if(document.input) {
document.input.subject.value = subject;
document.input.message.focus();
}
}
</script>
<table cellspacing="{INNERBORDERWIDTH}" cellpadding="{TABLESPACE}" width="{TABLEWIDTH}" align="center" class="tableborder">
<tr class="header"><td colspan="2"><table cellspacing="0" cellpadding="0" border="0" width="100%" class="smalltxt" style="table-layout: fixed; word-wrap: break-word">
<tr style="color: {HEADERTEXT}"><td class="bold" width="60%">{lang subject}: $thread[subject]</td>
<td width="40%" align="right" nowrap><table cellspacing="0" cellpadding="0" border="0"><tr>
<!--{if $visitedforums}-->
<td><select style="width: 12em" onchange="if(this.options[this.selectedIndex].value != '')
window.location=('forumdisplay.php?fid='+this.options[this.selectedIndex].value+'&sid=$sid')">
<option value="">{lang visited_forums}</option>$visitedforums</select></td>
<!--{/if}-->
<!--{if $searchbox == 2 || $searchbox == 3}-->
<td> <input type="text" name="searchbox" value="{lang keyword} ..." size="10" class="altbg2" onMouseOver="this.focus()" onFocus="this.select()"></td><td valign="bottom"> <input type="button" value="{lang search}" style="height: 1.8em" onclick="window.open('search.php?srchtype=qihoo&srchtxt='+findobj('searchbox').value+'&searchsubmit=yes');"></td>
<!--{/if}-->
</tr></table></td></tr></table></td></tr>
<!--{if $thread['modaction'] || $thread['blog'] || $thread['readperm'] || $thread['price'] > 0}-->
<tr class="category"><td colspan="2" align="center" class="bold">
<!--{if $thread['modaction']}--> {lang thread_mod_by} <!--{/if}-->
<!--{if $thread['blog']}--> <a href="blog.php?uid=$thread[authorid]" target="_blank">{lang thread_blog}</a> <!--{/if}-->
<!--{if $thread['readperm']}--> {lang readperm_thread} <span class=\"bold\">$thread[readperm]</span> <!--{/if}-->
<!--{if $thread['price'] > 0}--> <a href="misc.php?action=viewpayments&tid=$tid">{lang price_thread} {$extcredits[$creditstrans][title]} <span class=\"bold\">$thread[price]</span> {$extcredits[$creditstrans][unit]}</a> <!--{/if}-->
</td></tr>
<!--{/if}-->
<form method="post" name="delpost" action="topicadmin.php?action=delpost&fid=$fid&tid=$tid&page=$page">
<input type="hidden" name="formhash" value="{FORMHASH}">
<!--{loop $postlist $post}-->
<tr><td colspan="2" class="singleborder">$post[newpostanchor] $post[lastpostanchor]</td></tr>
<tr class="$post[thisbg]" height="100%">
<!--左侧美化开始-->
{template viewthread_left}
<!--左侧美化结束-->
<td width="79%" valign="top">
<table width="100%" height="100%" border="0" cellspacing="0" cellpadding="0" style="table-layout: fixed; word-wrap: break-word">
<tr><td valign="top">
<!--{if $avatarshowpos == 1}--><div style="float: right">$post[avatarshow]</div><!--{/if}-->
$post[ww] <script language="JavaScript" type="text/javascript">
<!--
document.write('<object classid="clsid27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="20" height="20">');
document.write('<param name="wmode" value="transparent">');
document.write('<param name="movie" value="http://cb.kingsoft.com/resource/a/en/$post[szm]/$post[newdc].swf" />');
document.write('<param name="quality" value="high" />');
document.write('<embed src="http://cb.kingsoft.com/resource/a/en/$post[szm]/$post[newdc].swf" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="20" height="20"></embed>');
document.write('</object>');
//-->
</script><br> <a name="pid$post[pid]" href="misc.php?action=viewratings&tid=$tid&pid=$post[pid]" alt="{lang rate_view}">$post[ratings]</a>
<!--{if !empty($advlist['thread'][$post['count']])}--><span class="smalltxt"><span class="bold">[{lang advertisement}]:</span> $advlist[thread][$post[count]]</span><hr width="100%" style="height: 1px; color: {INNERBORDERCOLOR}"><!--{/if}-->
<!--{if $post['subject']}--><span class="smalltxt"><span class="bold">$post[subject]</span></span><br><br><!--{/if}-->
<!--{if $bannedmessages && (($post['authorid'] && !$post['username']) || ($post['groupid'] == 4 || $post['groupid'] == 5))}-->
{lang message_banned}
<!--{else}-->
<span style="font-size: {MSGFONTSIZE}">$post[message]</span>
<!--{if $post['attachment']}-->
<br><br><img src="images/attachicons/common.gif"> {lang attachment}: <i>{lang attach_nopermission}</i>
<!--{else}-->
<!--{loop $post['attachments'] $attach}-->
<br><br>$attach[attachicon]
<!--{if $attach['attachimg']}-->
<a href="member.php?action=credits&view=getattach" title="{lang credits_policy_view}" target="_blank">{lang attach_img}</a>:
<!--{if $attach['readperm']}-->, {lang readperm} $attach[readperm]<!--{/if}-->
<!--{if $attach['description']}-->[{$attach[description]}]<!--{/if}--> <a href="attachment.php?aid=$attach[aid]" target="_blank" class="bold">$attach[filename]</a> ($attach[dateline], $attach[attachsize])<br><br>
<!--{if $attachrefcheck}-->
<img src="attachment.php?aid=$attach[aid]&noupdate=yes" border="0" onload="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt='{lang image_open_zoom}';}" onmouseover="if(this.resized) this.style.cursor='hand';" onclick="if(!this.resized) {return false;} else {window.open('attachment.php?aid=$attach[aid]');}" onmousewheel="return imgzoom(this);">
<!--{else}-->
<img src="$attachurl/$attach[attachment]" border="0" onload="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt='{lang image_open_zoom}';}" onmouseover="if(this.resized) this.style.cursor='hand';" onclick="if(!this.resized) {return false;} else {window.open('$attachurl/$attach[attachment]');}" onmousewheel="return imgzoom(this);">
<!--{/if}-->
<!--{else}-->
<a href="member.php?action=credits&view=getattach" title="{lang credits_policy_view}" target="_blank">{lang attachment}</a>:
<!--{if $attach['description']}-->[{$attach[description]}]<!--{/if}--> <a href="attachment.php?aid=$attach[aid]" target="_blank" class="bold">$attach[filename]</a> ($attach[dateline], $attach[attachsize])<br>
<span class="smalltxt">{lang attach_download_count} $attach[downloads]
<!--{if $attach['readperm']}-->, {lang readperm} $attach[readperm]<!--{/if}--></span><br>
<!--{/if}-->
<!--{/loop}-->
<!--{/if}-->
<!--{if $post['signature']}--><br><br><br></td></tr><tr><td valign="bottom" $maxsigrows><img src="images/common/sigline.gif"><br>$post[signature]<!--{/if}-->
<!--{/if}-->
</td></tr></table>
</td></tr>
<tr class="$post[thisbg]"><td valign="middle">
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="smalltxt">
<tr><td align="left"><!--{if $forum['ismoderator'] && $allowdelpost}--><!--{if $post['number'] == 1}--><input type="checkbox" disabled><!--{else}--><input type="checkbox" name="delete[]" value="$post[pid]"><!--{/if}--><!--{/if}-->
$post[dateline]</td><td align="right"><a href="###" class="bold" onclick="window.clipboardData.setData('text','{$boardurl}viewthread.php?tid=$tid&page=$page#pid$post[pid]')">#$post[number]</a></td></tr></table>
</td><td valign="bottom">
<table width="100%" height="100%" border="0" cellspacing="2" cellpadding="0">
<tr class="smalltxt"><td align="left">
<!--{if $post['username']}-->
<a href="viewpro.php?uid=$post[authorid]"><img src="{IMGDIR}/profile.gif" border="0" align="absmiddle" alt="{lang view_profile}"></a>
<!--{if $post['site']}--><a href="$post[site]" target="_blank"><img src="{IMGDIR}/site.gif" border="0" align="absmiddle" alt="{lang visit_home}"></a> <!--{/if}-->
<!--{if $post['allowuseblog']}--><a href="blog.php?uid=$post[authorid]" target="_blank"><img src="{IMGDIR}/blog.gif" border="0" align="absmiddle" alt="{lang blog}"></a> <!--{/if}-->
<a href="pm.php?action=send&uid=$post[authorid]" target="_blank"><img src="{IMGDIR}/pm.gif" border="0" align="absmiddle" alt="{lang send_pm}"></a>
<!--{if $post['qq']}--><a href="http://wpa.qq.com/msgrd?V=1&Uin=$post[qq]&Site=$bbname&Menu=yes" target="_blank"><img src="http://wpa.qq.com/pa?p=1post[qq]:4" align="absmiddle" border="0" alt="QQ"></a> <!--{/if}-->
<!--{if $post['icq']}--><a href="http://wwp.icq.com/scripts/search.dll?to=$post[icq]" target="_blank"><img src="http://web.icq.com/whitepages/online?icq=$post[icq]&img=5" alt="ICQ {lang online_status}" border="0" align="absmiddle"></a> <!--{/if}-->
<!--{if $post['yahoo']}--><a href="http://edit.yahoo.com/config/send_webmesg?.target=$post[yahoo]&.src=pg" target="_blank"><img src="{IMGDIR}/yahoo.gif" alt="Yahoo!" border="0" align="absmiddle"></a> <!--{/if}-->
<!--{if $post['taobao']}--><a target="_blank" href="http://amos1.taobao.com/msg.ww?v=2&uid=$post[taobao]&s=2"><img src="http://amos1.taobao.com/online.ww?v=2&uid=$post[taobao]&s=2" alt="{lang taobao}" border="0" align="absmiddle"></a> <!--{/if}-->
<!--{/if}-->
</td><td align="right">
<!--{if $forum['ismoderator'] || $post['authorid'] == $discuz_uid}--> <a href="post.php?action=edit&fid=$fid&tid=$tid&pid=$post[pid]&page=$page&extra=$extra"><img src="{IMGDIR}/edit.gif" border="0" align="absmiddle" alt="{lang edit_post}"></a><!--{/if}-->
<!--{if $allowpostreply}--> <a href="post.php?action=reply&fid=$fid&tid=$tid&repquote=$post[pid]&extra=$extra"><img src="{IMGDIR}/quote.gif" border="0" align="absmiddle" alt="{lang reply_quote}"></a><!--{/if}-->
<!--{if $discuz_uid && $reportpost}--> <a href="misc.php?action=report&fid=$fid&tid=$tid&pid=$post[pid]&page=$page"><img src="{IMGDIR}/report.gif" border="0" align="absmiddle" alt="{lang report_to_moderator}"></a><!--{/if}-->
<!--{if $raterange && $post['authorid']}--> <a href="misc.php?action=rate&tid=$tid&pid=$post[pid]&page=$page"><img src="{IMGDIR}/rate.gif" border="0" align="absmiddle" alt="{lang rate_this_post}"></a><!--{/if}-->
<!--{if $fastpost && $allowpostreply}--><a href="###" onclick="fastreply('{lang post_fastreply_author}')"><img src="{IMGDIR}/fastreply.gif" border="0" align="absmiddle" alt="{lang reply}"></a><!--{/if}-->
<a href="###" onclick="scroll(0,0)"><img src="{IMGDIR}/top.gif" border="0" align="absmiddle" alt="{lang top}"></a>
</td></tr></table>
</td></tr>
<!--{/loop}-->
</form></table>
<table width="{TABLEWIDTH}" cellspacing="0" cellpadding="0" align="center">
<tr>
<td valign="top">$multipage</td><td align="right">
<!--{if $allowpost || !$discuz_uid}--> <a href="post.php?action=newthread&fid=$fid&extra=$extra"><img src="{IMGDIR}/newtopic.gif" border="0"></a><!--{/if}-->
<!--{if $allowpostpoll || !$discuz_uid}--> <a href="post.php?action=newthread&fid=$fid&extra=$extra&poll=yes"><img src="{IMGDIR}/poll.gif" border="0"></a><!--{/if}-->
<!--{if ($allowpost || !$discuz_uid) && $allowposttrade}--> <a href="post.php?action=newthread&fid=$fid&extra=$extra&trade=yes"><img src="{IMGDIR}/newtrade.gif" border="0"></a><!--{/if}-->
<!--{if $allowpostreply || !$discuz_uid}--> <a href="post.php?action=reply&fid=$fid&tid=$tid&extra=$extra"><img src="{IMGDIR}/reply.gif" border="0"></a><!--{/if}--></td></tr>
</table>
<!--{if $fastpost && $allowpostreply}-->
<script language="JavaScript">
var postminchars = parseInt('$minpostsize');
var postmaxchars = parseInt('$maxpostsize');
var disablepostctrl = parseInt('$disablepostctrl');
function validate(theform) {
if (theform.message.value == "" && theform.subject.value == "") {
alert("{lang post_subject_and_message_isnull}");
return false;
} else if (theform.subject.value.length > 80) {
alert("{lang post_subject_toolang}");
return false;
}
if (!disablepostctrl && ((postminchars != 0 && theform.message.value.length < postminchars) || (postmaxchars != 0 && theform.message.value.length > postmaxchars))) {
alert("{lang post_message_length_invalid}\n\n{lang post_curlength}: "+theform.message.value.length+" {lang bytes}\n{lang board_allowed}: "+postminchars+" {lang to} "+postmaxchars+" {lang bytes}");
return false;
}
theform.replysubmit.disabled = true;
return true;
}
</script>
<form method="post" name="input" action="post.php?action=reply&fid=$fid&tid=$tid&extra=$extra&replysubmit=yes" onSubmit="return validate(this)">
<input type="hidden" name="formhash" value="{FORMHASH}">
<table cellspacing="{INNERBORDERWIDTH}" cellpadding="{TABLESPACE}" width="{TABLEWIDTH}" align="center" class="tableborder">
<tr><td colspan="2" class="header"><a href="member.php?action=credits&view=forum_reply&fid=$fid" target="_blank"><img src="{IMGDIR}/credits.gif" alt="{lang credits_policy_view}" align="right" border="0"></a>{lang post_fastreply}</td></tr>
{template post_bbinsert}
<tr>
<td width="18%" class="altbg1">{lang subject}:</td>
<td width="82%" class="altbg2"><input type="text" name="subject" size="80" value="" tabindex="1"> <span class="smalltxt">({lang optional})</span></td>
</tr>
<tr>
<td width="18%" class="altbg1" valign="top">{$smilies}{lang options}:<br><span class="smalltxt">
<input type="checkbox" name="parseurloff" value="1"> {lang disable} {lang post_parseurl}<br>
<input type="checkbox" name="smileyoff" value="1"> {lang disable} <a href="faq.php?page=messages#6" target="_blank">{lang post_smilies}</a><br>
<input type="checkbox" name="bbcodeoff" value="1"> {lang disable} <a href="faq.php?page=misc#1" target="_blank">{lang post_discuzcode}</a><br>
<input type="checkbox" name="usesig" value="1" $usesigcheck> {lang post_show_sig}<br>
<input type="checkbox" name="emailnotify" value="1"> {lang post_email_notify}</span>
</td>
<td width="82%" class="altbg2"><span class="smalltxt">
<textarea rows="7" name="message" style="width: 80%; word-break: break-all" onKeyDown="ctlent(event);" tabindex="2"></textarea><br>
<IFRAME id=rtf style="WIDTH: 0px; HEIGHT: 0px" marginWidth=0 marginHeight=0 src="about:blank" scrolling=no></IFRAME><INPUT onclick="document.getElementById('message').value += trans()" type=button value=自娱自乐UBB转贴助手><SCRIPT>rtf.document.designMode="On";</SCRIPT><br>
<input type="submit" name="replysubmit" value="{lang post_topicsubmit}" tabindex="3">
<input type="submit" name="previewpost" value="{lang post_previewpost}" tabindex="4">
<input type="reset" name="topicsreset" value="{lang post_topicreset}" tabindex="5"> {lang post_submit_hotkey}</span>
</td></tr></table></form>
<!--{/if}-->
<br><table cellspacing="{INNERBORDERWIDTH}" cellpadding="{TABLESPACE}" align="center" class="tableborder">
<tr class="smalltxt"><td class="altbg2" align="center" nowrap>
<a href="viewthread.php?action=printable&tid=$tid" target="_blank">{lang thread_printable}</a> |
<a href="misc.php?action=emailfriend&tid=$tid">{lang thread_email_friend}</a> |
<a href="memcp.php?action=subscriptions&subadd=$tid">{lang thread_subscribe}</a> |
<a href="memcp.php?action=favorites&favadd=$tid">{lang thread_favorite}</a>
<!--{if $thread['authorid'] && ($thread['authorid'] == $discuz_uid || $forum['ismoderator'])}-->
<!--{if $thread['blog']}-->
| <a href="misc.php?action=blog&tid=$tid">{lang blog_remove}</a>
<!--{elseif $allowuseblog && $forum['allowblog'] && $thread['authorid'] == $discuz_uid}-->
| <a href="misc.php?action=blog&tid=$tid">{lang blog_add}</a>
<!--{/if}-->
<!--{/if}-->
</td></tr></table>
<br><br><table width="{TABLEWIDTH}" cellspacing="0" cellpadding="0" align="center" class="outertxt">
<tr><td align="left" class="smalltxt">
<!--{if $forumjump}-->
<span class="bold">{lang forum_jump}:</span>
<select onchange="if(this.options[this.selectedIndex].value != '') {
window.location=('forumdisplay.php?fid='+this.options[this.selectedIndex].value+'&sid=$sid') }">
$forumselect
</select>
<!--{/if}-->
</td><td align="right" class="smalltxt">
<!--{if $forum['ismoderator']}-->
<span class="bold">{lang admin_modoptions}:</span>
<select name="action" id="action" onchange="if(this.options[this.selectedIndex].value != '') { if(this.options[this.selectedIndex].value != 'delpost') {
window.location=('topicadmin.php?tid=$tid&fid=$fid&action='+this.options[this.selectedIndex].value+'&sid=$sid');
} else { document.delpost.submit(); } }">
<option value="" selected>{lang admin_modoptions}</option>
<!--{if $allowdelpost}-->
<option value="delpost">{lang admin_delpost}</option>
<option value="delete">{lang admin_delthread}</option>
<!--{/if}-->
<option value="close"><!--{if $thread['closed']}-->{lang admin_open}<!--{else}-->{lang admin_close}<!--{/if}--></option>
<option value="move">{lang admin_move}</option>
<option value="highlight">{lang admin_highlight}</option>
<option value="digest"><!--{if $thread['digest']}-->{lang admin_digest_remove}<!--{else}-->{lang admin_digest_add}<!--{/if}--></option>
<!--{if $allowstickthread}--><option value="stick"><!--{if $thread['displayorder']}-->{lang admin_unstick}<!--{else}-->{lang admin_stick}<!--{/if}--></option><!--{/if}-->
<!--{if $thread['price'] > 0 && $allowrefund}--><option value="refund">{lang admin_refund}</option><!--{/if}-->
<option value="split">{lang admin_split}</option>
<option value="merge">{lang admin_merge}</option>
<option value="bump">{lang admin_bump}</option>
<option value="repair">{lang admin_repair}</option>
</select>
<!--{/if}-->
</td>
</tr></table>
{template footer} |