0

私はbutton_toを取得する必要がありますが、qoutesはありません

レンダリング中

button_to "Delete",
  radio_tag_path(tag),
  :method=>:delete,
  :class=>:destroy,
  :confirm=>"Are you sure?"

出力は

<form action="/radio/tags/654" class="button_to" method="post">
  <div>
    <input name="_method" type="hidden" value="delete" />
    <input class="destroy" data-confirm="Are you sure?" type="submit" value="Delete" />
    <input name="authenticity_token" type="hidden" value="eXM0McnTzuhnYIxrLLYF7kjp76fdMdZpq6HPc++ogog=" />
  </div>
</form>

しかし、私は引用なしで必要です

私がレンダリングしたよりも

(button_to "Delete",
  radio_tag_path(tag),
  :method=>:delete,
  :class=>:destroy,
  :confirm=>"Are you sure?"
).gsub('\"','\'')

しかし、出力は html_safe のようになります

&lt;form action=&quot;/radio/tags/654&quot; class=&quot;button_to&quot; method=&quot;post&quot;&gt;&lt;div&gt;&lt;input name=&quot;_method&quot; type=&quot;hidden&quot; value=&quot;delete&quot; /&gt;&lt;input class=&quot;destroy&quot; data-confirm=&quot;Are you sure?&quot; type=&quot;submit&quot; value=&quot;Delete&quot; /&gt;&lt;input name=&quot;authenticity_token&quot; type=&quot;hidden&quot; value=&quot;eXM0McnTzuhnYIxrLLYF7kjp76fdMdZpq6HPc++ogog=&quot; /&gt;&lt;/div&gt;&lt;/form&gt;

引用符を削除しても html タグを使用するにはどうすればよいですか

4

1 に答える 1