查看完整版本: [08-25] 當 "Html 代码 可用" 時做成的錯誤

rengo 2006-8-25 12:05

[08-25] 當 "Html 代码 可用" 時做成的錯誤

當 "Html 代码 可用" 時做成的錯誤

原貼:http://dev.freediscuz.net/dev/viewthread.php?tid=12696&extra=page%3D1

作者:AndyGod

錯誤說明: 當開啟了 Html 代码 可用 時, 會做成貼文時不能自動換行, 就是說每行不會自動地加入 <br /> 。

解決方法
# 打開 discuzcode.func.php
# 找


[code]return $htmlon || $allowhtml ? $message : nl2br(str_replace(array("\t", '   ', '  '), array('&nbsp; &nbsp; &nbsp; &nbsp; ', '&nbsp; &nbsp;', '&nbsp;&nbsp;'), $message));[/code]
# 改為


[code]return $htmlon || $allowhtml ? nl2br($message) : nl2br(str_replace(array("\t", '   ', '  '), array('&nbsp; &nbsp; &nbsp; &nbsp; ', '&nbsp; &nbsp;', '&nbsp;&nbsp;'), $message));[/code]
# 完成 ^^
頁: [1]
查看完整版本: [08-25] 當 "Html 代码 可用" 時做成的錯誤