discourse/app/views/topics/show.html.erb

34 lines
1.0 KiB
Plaintext
Raw Normal View History

2013-02-06 03:16:51 +08:00
<h2>
2013-02-13 19:15:10 +08:00
<%= render_topic_title(@topic_view.topic) %>
2013-02-06 03:16:51 +08:00
</h2>
2013-02-13 14:43:21 +08:00
<hr/>
<% @topic_view.posts.each do |post| %>
<% if post.user %>
<div class='creator'>
#<%=post.post_number%> <%= t 'by'%>: <b><%= post.user.name %></b>, <%= post.created_at.to_formatted_s(:long_ordinal) %>
</div>
<div class='post'>
<%= post.cooked.html_safe %>
</div>
<hr/>
<% end %>
2013-02-06 03:16:51 +08:00
<% end %>
<% if @topic_view.next_page %>
2013-02-06 03:16:51 +08:00
<p>
2013-03-02 00:04:13 +08:00
<b><%= link_to(t('next_page').html_safe, @topic_view.next_page_path ) %></b>
2013-02-06 03:16:51 +08:00
</p>
<% end %>
2013-02-13 14:43:21 +08:00
<p><%= t 'powered_by_html' %></p>
<% content_for :head do %>
<%= auto_discovery_link_tag(@topic_view, {action: :feed, format: :rss, slug: @topic_view.topic.slug, topic_id: @topic_view.topic.id}, title: t('rss_posts_in_topic', topic: @topic_view.title), type: 'application/rss+xml') %>
<%= crawlable_meta_data(title: @topic_view.title,
description: @topic_view.summary,
image: @topic_view.image_url) %>
<% end %>
<% content_for(:title) { @topic_view.title } %>