Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Set up the Application Layout with flash messages and Devise links
- Loading branch information
Showing
4 changed files
with
35 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,9 @@ | |||
<% if user_signed_in? %> | |||
<li> | |||
<%= link_to('Logout', destroy_user_session_path) %> | |||
</li> | |||
<% else %> | |||
<li> | |||
<%= link_to('Login', new_user_session_path) %> | |||
</li> | |||
<% end %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,9 @@ | |||
<% if user_signed_in? %> | |||
<li> | |||
<%= link_to('Edit account', edit_user_registration_path) %> | |||
</li> | |||
<% else %> | |||
<li> | |||
<%= link_to('Sign up', new_user_registration_path) %> | |||
</li> | |||
<% end %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -1,14 +1,18 @@ | |||
<!DOCTYPE html> | <!DOCTYPE html> | ||
<html> | <html> | ||
<head> | <head> | ||
<title>Rails3SubdomainDevise</title> | <title>Rails3-Subdomain-Devise</title> | ||
<%= stylesheet_link_tag :all %> | <%= stylesheet_link_tag :all %> | ||
<%= javascript_include_tag :defaults %> | <%= javascript_include_tag :defaults %> | ||
<%= csrf_meta_tag %> | <%= csrf_meta_tag %> | ||
</head> | </head> | ||
<body> | <body> | ||
|
<ul class="hmenu"> | ||
<%= yield %> | <%= render 'devise/menu/registration_items' %> | ||
|
<%= render 'devise/menu/login_items' %> | ||
</ul> | |||
<p style="color: green"><%= notice %></p> | |||
<p style="color: red"><%= alert %></p> | |||
<%= yield %> | |||
</body> | </body> | ||
</html> | </html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,9 @@ | |||
ul.hmenu { | |||
list-style: none; | |||
margin: 0 0 2em; | |||
padding: 0; | |||
} | |||
|
|||
ul.hmenu li { | |||
display: inline; | |||
} |