Skip to content

Instantly share code, notes, and snippets.

@tubbo
Created March 27, 2010 18:34
Show Gist options
  • Select an option

  • Save tubbo/346272 to your computer and use it in GitHub Desktop.

Select an option

Save tubbo/346272 to your computer and use it in GitHub Desktop.
<div id="<%= post.id %>" class="blog_post ui-corner-all">
<div class="blog_post_header">
<h3><%= link_to post.title, blog_post_path(post), :class => 'title' %></h3>
<div class="blog_post_meta">
posted in
<%= link_to post.category.name, blog_category_path(post.category), :class => 'nobold' %>
<%= unless post.date
distance_of_time_in_words(post.created_at, Time.now)+' ago'
else
post.date
end
%>.
</div>
</div>
<div class="blog_post_body">
<div class="blog_post_attachment ui-corner-all">
<%= render_attachment(post.attachment) %>
</div>
<%=textilize post.body %>
<br /><br />
<% if post.created_at != post.updated_at then %>
<div class="last_updated">last updated <%= post.last_updated %></div>
<% end %>
</div>
<div class="blog_post_options">
<% if authorized? then %>
<%= link_to 'X', blog_post_path(post), :method => :delete, :title => 'delete' %> &middot;
<%= link_to '%', edit_blog_post_path(post), :title => 'edit' %> &middot;
<% end %>
<%= link_to '@', blog_post_path(post), :anchor => 'reply', :title => 'reply' %> &middot;
<%= link_to '#', blog_post_path(post), :title => 'show' %>
</div>
</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment