Commit 2819ced91eeac0760ee0722a601ea0f166f10933
1 parent
5b5b05f5
Exists in
remove_escaped_html
Fixed html that was being escaped
Showing
5 changed files
with
7 additions
and
9 deletions
Show diff stats
lib/proposals_discussion_plugin/topic_helper.rb
| ... | ... | @@ -6,7 +6,7 @@ module ProposalsDiscussionPlugin::TopicHelper |
| 6 | 6 | |
| 7 | 7 | content_tag(:div, ( |
| 8 | 8 | content_tag(:div, '', :class=>'topic-color', :style => "background-color: #{topic.color};") + |
| 9 | - content_tag(:h2, link_to(image_icon + content_tag(:span, topic.title), topic.view_url)) | |
| 9 | + content_tag(:h2, link_to(image_icon.html_safe + content_tag(:span, topic.title), topic.view_url)) | |
| 10 | 10 | ), :class => 'topic-title') |
| 11 | 11 | end |
| 12 | 12 | ... | ... |
views/content_viewer/discussion.html.erb
views/content_viewer/discussion_topics.html.erb
| ... | ... | @@ -2,7 +2,7 @@ |
| 2 | 2 | <%= javascript_include_tag 'plugins/proposals_discussion/proposals_list.js' %> |
| 3 | 3 | |
| 4 | 4 | <div class="description"> |
| 5 | - <%= discussion.body %> | |
| 5 | + <%= discussion.body.to_s.html_safe %> | |
| 6 | 6 | </div> |
| 7 | 7 | |
| 8 | 8 | <% if discussion.allow_create?(user) %> |
| ... | ... | @@ -27,4 +27,3 @@ |
| 27 | 27 | </div> |
| 28 | 28 | <% end %> |
| 29 | 29 | </div> |
| 30 | - | ... | ... |
views/content_viewer/proposal.html.erb
| 1 | 1 | <span class="created-at"> |
| 2 | - <span class="date"><%= show_date(proposal.published_at) %></span> | |
| 3 | - <span class="author"><%= _(", by %s") % (proposal.author ? link_to(proposal.author_name, proposal.author_url) : proposal.author_name) %></span> | |
| 4 | - <span class="comments"><%= _(" - %s") % link_to_comments(proposal) %></span> | |
| 2 | + <span class="date"><%= show_date(proposal.published_at) %></span><span class="author"><%= _(", by %s").html_safe % (proposal.author ? link_to(proposal.author_name, proposal.author_url) : proposal.author_name) %></span> | |
| 3 | + <span class="comments"><%= _(" - %s").html_safe % link_to_comments(proposal) %></span> | |
| 5 | 4 | </span> |
| 6 | 5 | |
| 7 | 6 | <div class="discussion"> |
| ... | ... | @@ -17,7 +16,7 @@ |
| 17 | 16 | </div> |
| 18 | 17 | |
| 19 | 18 | <div class="body"> |
| 20 | - <div class="content"><%= proposal.body %></div> | |
| 19 | + <div class="content"><%= proposal.body.to_s.html_safe %></div> | |
| 21 | 20 | </div> |
| 22 | 21 | |
| 23 | 22 | <% if proposal.created_by == user && !proposal.published %> | ... | ... |