Merge pull request #2762 from techAPJ/patch-1

Show category badge on 404 page topics
This commit is contained in:
Jeff Atwood 2014-09-06 12:21:34 -07:00
commit f2c3a824e7
1 changed files with 2 additions and 2 deletions

View File

@ -6,7 +6,7 @@
<div class="span8 popular-topics">
<h2 class="popular-topics-title"><%= t 'page_not_found.popular_topics' %></h2>
<% @top_viewed.each do |t| %>
<%= link_to t.title, t.relative_url %><br/>
<span style="line-height:2;"><%= link_to t.title, t.relative_url %><% if !t.category.uncategorized? %>&nbsp;&nbsp;<a href="<%= t.category.url %>" class="badge badge-category" style="background-color: #<%= t.category.color %>; color: #<%= t.category.text_color %>"><%= t.category.name %></a><% end %></span><br/>
<% end %>
<br/>
<a href="/latest" class="btn"><%= t 'page_not_found.see_more' %>&hellip;</a>
@ -14,7 +14,7 @@
<div class="span8 recent-topics">
<h2 class="recent-topics-title"><%= t 'page_not_found.recent_topics' %></h2>
<% @recent.each do |t| %>
<%= link_to t.title, t.relative_url %><br/>
<span style="line-height:2;"><%= link_to t.title, t.relative_url %><% if !t.category.uncategorized? %>&nbsp;&nbsp;<a href="<%= t.category.url %>" class="badge badge-category" style="background-color: #<%= t.category.color %>; color: #<%= t.category.text_color %>"><%= t.category.name %></a><% end %></span><br/>
<% end %>
<br/>
<a href="/latest" class="btn"><%= t 'page_not_found.see_more' %>&hellip;</a>