Skip to content

Commit

Permalink
Added content_for :title to every view
Browse files Browse the repository at this point in the history
  • Loading branch information
mischa78 committed Jan 8, 2011
1 parent 6808ef6 commit 9124f2b
Show file tree
Hide file tree
Showing 16 changed files with 49 additions and 15 deletions.
4 changes: 3 additions & 1 deletion app/views/admins/new.html.erb
@@ -1,4 +1,6 @@
<h1>Create admin</h1>
<% content_for :title, 'Create admin' -%>

<h1><%= content_for :title %></h1>
<p>
Boxroom does not have an administrator yet. Create one here.
</p>
Expand Down
4 changes: 3 additions & 1 deletion app/views/files/edit.html.erb
@@ -1,4 +1,6 @@
<h1>Rename file</h1>
<% content_for :title, 'Rename file' -%>

<h1><%= content_for :title %></h1>
<% if flash[:notice] -%>
<p class="notice">
<%= flash[:notice] %>
Expand Down
4 changes: 3 additions & 1 deletion app/views/files/new.html.erb
@@ -1,4 +1,6 @@
<h1>Upload file</h1>
<% content_for :title, 'Upload file' -%>

<h1><%= content_for :title %></h1>
<%= form_for [@parent_folder, @file], :url => { :action => 'create' }, :html => { :multipart => true } do |f| %>
<%= f.error_messages %>
<p>
Expand Down
4 changes: 3 additions & 1 deletion app/views/folders/edit.html.erb
@@ -1,4 +1,6 @@
<h1>Rename folder</h1>
<% content_for :title, 'Rename folder' -%>

<h1><%= content_for :title %></h1>
<% if flash[:notice] -%>
<p class="notice">
<%= flash[:notice] %>
Expand Down
4 changes: 3 additions & 1 deletion app/views/folders/new.html.erb
@@ -1,4 +1,6 @@
<h1>New folder</h1>
<% content_for :title, 'New folder' -%>

<h1><%= content_for :title %></h1>
<%= form_for [@parent_folder, @folder], :url => { :action => 'create' } do |f| %>
<%= render :partial => 'form', :locals => { :f => f } %>
<% end %>
4 changes: 3 additions & 1 deletion app/views/folders/show.html.erb
@@ -1,4 +1,6 @@
<h1><%= @folder.name %></h1>
<% content_for :title, @folder.name -%>

<h1><%= content_for :title %></h1>
<% unless @folder.is_root? -%>
<p>
<%= breadcrumbs(@folder) %>
Expand Down
4 changes: 3 additions & 1 deletion app/views/groups/edit.html.erb
@@ -1,4 +1,6 @@
<h1>Rename group</h1>
<% content_for :title, 'Rename group' -%>

<h1><%= content_for :title %></h1>
<% if flash[:notice] -%>
<p class="notice">
<%= flash[:notice] %>
Expand Down
4 changes: 3 additions & 1 deletion app/views/groups/index.html.erb
@@ -1,4 +1,6 @@
<h1>Groups</h1>
<% content_for :title, 'Groups' -%>

<h1><%= content_for :title %></h1>
<% if flash[:error] -%>
<p class="error">
<%= flash[:error] %>
Expand Down
4 changes: 3 additions & 1 deletion app/views/groups/new.html.erb
@@ -1,4 +1,6 @@
<h1>New group</h1>
<% content_for :title, 'New group' -%>

<h1><%= content_for :title %></h1>
<%= form_for @group, :url => { :action => 'create' } do |f| %>
<%= render :partial => 'form', :locals => { :f => f } %>
<% end %>
4 changes: 4 additions & 0 deletions app/views/layouts/application.html.erb
@@ -1,7 +1,11 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<% if content_for? :title -%>
<title>Boxroom | <%= content_for :title %></title>
<% else -%>
<title>Boxroom</title>
<% end -%>
<%= stylesheet_link_tag :all %>
<%= javascript_include_tag :defaults %>
<%= csrf_meta_tag %>
Expand Down
4 changes: 3 additions & 1 deletion app/views/reset_password/edit.html.erb
@@ -1,4 +1,6 @@
<h1>Reset password</h1>
<% content_for :title, 'Reset password' -%>

<h1><%= content_for :title %></h1>
<%= form_for @user, :url => { :action => 'update' } do |f| %>
<%= f.error_messages %>
<p>
Expand Down
4 changes: 3 additions & 1 deletion app/views/reset_password/new.html.erb
@@ -1,4 +1,6 @@
<h1>Reset password</h1>
<% content_for :title, 'Reset password' -%>

<h1><%= content_for :title %></h1>
<% if flash[:notice] -%>
<p class="notice">
<%= flash[:notice] %>
Expand Down
4 changes: 3 additions & 1 deletion app/views/sessions/new.html.erb
@@ -1,4 +1,6 @@
<h1>Sign in</h1>
<% content_for :title, 'Sign in' -%>

<h1><%= content_for :title %></h1>
<% if flash[:notice] -%>
<p class="notice">
<%= flash[:notice] %>
Expand Down
4 changes: 3 additions & 1 deletion app/views/users/edit.html.erb
@@ -1,4 +1,6 @@
<h1><%= @title %></h1>
<% content_for :title, @title -%>

<h1><%= content_for :title %></h1>
<% if flash[:notice] -%>
<p class="notice">
<%= flash[:notice] %>
Expand Down
4 changes: 3 additions & 1 deletion app/views/users/index.html.erb
@@ -1,4 +1,6 @@
<h1>Users</h1>
<% content_for :title, 'Users' -%>

<h1><%= content_for :title %></h1>
<% if flash[:error] -%>
<p class="error">
<%= flash[:error] %>
Expand Down
4 changes: 3 additions & 1 deletion app/views/users/new.html.erb
@@ -1,4 +1,6 @@
<h1>New user</h1>
<% content_for :title, 'New user' -%>

<h1><%= content_for :title %></h1>
<%= form_for @user, :url => { :action => 'create' } do |f| %>
<%= render :partial => 'form', :locals => { :f => f } %>
<% end %>

0 comments on commit 9124f2b

Please sign in to comment.