Skip to content

Instantly share code, notes, and snippets.

@lmarburger
Created December 14, 2010 18:30
Show Gist options
  • Star 3 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save lmarburger/740835 to your computer and use it in GitHub Desktop.
Save lmarburger/740835 to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html>
<head>
<title>Site</title>
</head>
<body class="app">
<%= render :partial => 'layouts/flashes' %>
<%= yield %>
</body>
</html>
<%= render :layout => 'layouts/base' do %>
<%= yield %>
<% end %>
<h1>Listing projects</h1>
<table id="projects">
<tr>
<th>Name</th>
<th></th>
</tr>
<% @projects.each do |project| %>
<tr>
<td><%= link_to project.name, project %></td>
<td><%= link_to 'Destroy', project, :confirm => 'Are you sure?', :method => :delete %></td>
</tr>
<% end %>
</table>
<br />
<%= link_to 'New Project', new_project_path %>
@grillermo
Copy link

Could you add to this example how it would look the markup for an action in a specific controller?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment