Skip to content

Commit

Permalink
Need to call html_safe on unsafe string before concatenating it to sa…
Browse files Browse the repository at this point in the history
…fe string.

Read explanation at
#325 (comment)
07945.

Closes #325.
  • Loading branch information
ugisozols committed Jun 21, 2013
1 parent a7cd823 commit a8af874
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions app/views/refinery/blog/posts/_nav.html.erb
@@ -1,17 +1,17 @@
<nav id="next_prev_article">
<% if @post.next.present? -%>
<%= link_to (h(truncate(@post.next.title)) + " &#187;").html_safe,
refinery.blog_post_path(@post.next),
<%= link_to h(truncate(@post.next.title)) + " &#187;".html_safe,
refinery.blog_post_path(@post.next),
:class => 'next' %>
<% end -%>
<%= link_to t('blog_home', :scope => 'refinery.blog.posts.show'),
refinery.blog_root_path,
<%= link_to t('blog_home', :scope => 'refinery.blog.posts.show'),
refinery.blog_root_path,
:class => 'home' %>
<% if @post.prev.present? -%>
<%= link_to ("&#171; " + h(truncate(@post.prev.title))).html_safe,
refinery.blog_post_path(@post.prev),
<%= link_to "&#171; ".html_safe + h(truncate(@post.prev.title)),
refinery.blog_post_path(@post.prev),
:class => 'prev' %>
<% end -%>
</nav><!-- /next_prev_article -->

0 comments on commit a8af874

Please sign in to comment.