御時間ありがとうございます!
私はRailsが初めてで、少し混乱していview helper
ます。
で関数を定義しましたhelpers/application_helper.rb
。
def error_table()
return %{<table>...</table>}
end
error_table
で関数を呼び出しましたshow.html.erb
。
<%= error_table() %>
しかし、このページを表示すると、この文字列が表示されます<table>...</table>
。
HTMLソースコードを表示すると、次のようになります。<table>...</table>
このテーブルを表示する代わりに、html ページに挿入したいと考えています。私は何をすべきか?