Skip to content

Instantly share code, notes, and snippets.

@remear
Created August 14, 2010 04:47
Show Gist options
  • Save remear/523985 to your computer and use it in GitHub Desktop.
Save remear/523985 to your computer and use it in GitHub Desktop.
# Layout
<div id="toolbar">
<ul id="breadcrumbs" style="width:400px; float:left">
<li id="home"><%= link_to '&nbsp;', root_url %></li>
<%= yield :breadcrumbs %>
</ul>
<ul id="actions" style="width:300px; text-align:right; float:right">
<%= yield :actions %>
</ul>
</div>
# View
<% content_for(:breadcrumbs) do %>
<li><%= link_to 'Bookmarks', bookmarks_path %></li>
<li><%= link_to @bookmark.language.name, bookmarks_path + "/#{@bookmark.language.permalink}" %></li>
<li>Bookmarks</li>
<% end %>
<% content_for(:actions) do %>
<% if admin? %>
<li><%= link_to 'Edit', edit_bookmark_path(@bookmark) %></li>
<% end %>
<li class="last"><%= link_to 'Back', :back %></li>
<% end %>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment