本帖最后由 IsaacZ 于 2012-7-27 00:17 编辑
三、修改模板中写死的字符限制数:
1、找到文件\template\default\forum\post_editor_extra.htm的25到31行:
- <!--{if $_G[gp_action] != 'reply'}-->
- <span><input type="text" name="subject" id="subject" class="px" value="$postinfo[subject]" {if $_G[gp_action] == 'newthread'}onblur="if($('tags')){relatekw('-1','-1'{if $_G['group']['allowposttag']},function(){extraCheck(4)}{/if});doane();}"{/if} style="width: 25em" tabindex="1" /></span>
- <!--{else}-->
- <span id="subjecthide" class="z">RE: $thread[subject] [<a href="javascript:;">{lang modify}</a>]</span>
- <span id="subjectbox" style="display:none"><input type="text" name="subject" id="subject" class="px" value="" style="width: 25em" /></span>
- <!--{/if}-->
- <span id="subjectchk"{if $_G[gp_action] == 'reply'} style="display:none"{/if}>{lang comment_message1} <strong id="checklen">80</strong> {lang comment_message2}</span>
复制代码 以上只有一个参数是80,我看了下我的,如下,有3个80:- <!--{if $_GET[action] != 'reply'}-->
- <span><input type="text" name="subject" id="subject" class="px" value="$postinfo[subject]" {if $_GET[action] == 'newthread'}onblur="if($('tags')){relatekw('-1','-1'{if $_G['group']['allowposttag']},function(){extraCheck(4)}{/if});doane();}"{/if} onkeyup="strLenCalc(this, 'checklen', 80);" style="width: 25em" tabindex="1" /></span>
- <!--{else}-->
- <span id="subjecthide" class="z">RE: $thread[subject] [<a href="javascript:;" onclick="display('subjecthide');display('subjectbox');$('subject').value='RE: {echo dhtmlspecialchars(str_replace('\'', '\\\'', $thread[subject]))}';display('subjectchk');strLenCalc($('subject'), 'checklen', 80);return false;">{lang modify}</a>]</span>
- <span id="subjectbox" style="display:none"><input type="text" name="subject" id="subject" class="px" value="" onkeyup="strLenCalc(this, 'checklen', 80);" style="width: 25em" /></span>
- <!--{/if}-->
复制代码 楼主贴的是不是有问题? |