over 4 years ago
<%= "<h1>yooo</h1>" %>
<%= raw("<h1>mooo</h1>") %>
<%= h("<h1>hooo</h1>") %>

h => blacklist, before rails3, the html will be inserted into html unless you use h, after rails3, it becomes a default setting

Source

&lt;h1&gt;yooo&lt;/h1&gt;
<h1>mooo</h1>
&lt;h3 &gt;hooo&lt;/h3&gt;
← N+1 query, repack find_by_xxx →
 
comments powered by Disqus