久久久久av_欧美日韩一区二区在线_国产精品三区四区_日韩中字在线

Discuz! 官方交流社區

標題: 再問:本帖最后由xx于xx編輯 移到正文下面 [打印本頁]

作者: 一葦過江    時間: 2019-8-2 16:39
標題: 再問:本帖最后由xx于xx編輯 移到正文下面
本帖最后由 一葦過江 于 2019-8-2 17:16 編輯

以前看過一些方法,但好像都沒有效果:
(剛試過,以下方法可行)

帖子里的最后由xx于xx編輯這種備注性的提示信息顯示在帖子頂部占用很大位置(特別是手機版訪問時),非常別扭。

可以把它移到帖子正文底部。

1.打開/source/class/model/model_forum_post.php,找到約459行:

$this->param[‘message’] = lang(‘forum/misc’, $this->param[‘htmlon’] ? ‘post_edithtml’ : (!$this->forum[‘allowbbcode’] || $this->param[‘bbcodeoff’] ? ‘post_editnobbcode’ : ‘post_edit’), array(‘editor’ => $editor, ‘edittime’ => $edittime)) . $this->param[‘message’];

復制代碼

把最后的. $this->param[‘message’]移到前面,即

$this->param[‘message’] = $this->param[‘message’]. lang(‘forum/misc’, $this->param[‘htmlon’] ? ‘post_edithtml’ : (!$this->forum[‘allowbbcode’] || $this->param[‘bbcodeoff’] ? ‘post_editnobbcode’ : ‘post_edit’), array(‘editor’ => $editor, ‘edittime’ => $edittime));

2.打開/source/language/forum/lang_misc.php,找到第32—37行:

'post_edit' => "本帖最后由 {editor} 于 {edittime} 編輯\n\n",
'post_edit_regexp' => '/^\[i=s\] 本帖最后由 .*? 于 .*? 編輯 \[\/i\]\n\n/s',
'post_edithtml' => '本帖最后由 {editor} 于 {edittime} 編輯<br /><br />',
'post_edithtml_regexp' => '/^\[i=s\] 本帖最后由 .*? 于 .*? 編輯 \[\/i\]<br \/><br \/>/s',
'post_editnobbcode' => '[ 本帖最后由 {editor} 于 {edittime} 編輯 ]\n\n',
'post_editnobbcode_regexp' => '/^\[ 本帖最后由 .*? 于 .*? 編輯 \]\n\n/s',


去掉其中的^,即
'post_edit' => "本帖最后由 {editor} 于 {edittime} 編輯\n\n",
'post_edit_regexp' => '/\[i=s\] 本帖最后由 .*? 于 .*? 編輯 \[\/i\]\n\n/s',
'post_edithtml' => '本帖最后由 {editor} 于 {edittime} 編輯<br /><br />',
'post_edithtml_regexp' => '/\[i=s\] 本帖最后由 .*? 于 .*? 編輯 \[\/i\]<br \/><br \/>/s',
'post_editnobbcode' => '[ 本帖最后由 {editor} 于 {edittime} 編輯 ]\n\n',
'post_editnobbcode_regexp' => '/\[ 本帖最后由 .*? 于 .*? 編輯 \]\n\n/s',


作者: LCW    時間: 2019-8-2 17:11
提示: 作者被禁止或刪除 內容自動屏蔽
作者: 一葦過江    時間: 2019-8-2 17:15
剛試過,上面的方法是可行的,只是以前已經發布的帖子不會變更。




歡迎光臨 Discuz! 官方交流社區 (http://www.9999xn.com/) Powered by Discuz! W1.0