编程作业代码中不显示<和>
This commit is contained in:
parent
7fc9059a8d
commit
a4095adc59
|
@ -2345,6 +2345,6 @@ module ApplicationHelper
|
|||
|
||||
#将文本内的/n转换为<br>
|
||||
def text_format text
|
||||
text.gsub("\n","<br/>").html_safe
|
||||
text.gsub("<","<").gsub(">",">").gsub("\n","<br/>").html_safe
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue