<% if @action_name == "list" %>
<%= link_to "New Mailing List", :action => "new" %>
<%= link_to "Back", :controller => "account", :action => "welcome" %>
<% elsif @action_name == "edit" %>
<%= link_to "Back", controller.request.env["HTTP_REFERER"] %>
<% elsif @action_name == "new_mailinglist_class" %>
<%= link_to "Back", controller.request.env["HTTP_REFERER"] %>
<% elsif @action_name == "new" %>
<%= link_to "Back", controller.request.env["HTTP_REFERER"] %>
<% elsif @action_name == 'show' %>
<%= link_to "Edit Mailing List", :action => 'edit', :id => @mailinglist %>
<%= link_to "List Admin Messages", :controller => "mail_admin", :action => "list_admin_messages", :id => @mailinglist %>
<%= link_to "Back", :controller => "account", :action => "welcome" %>
<% end %>
<%= link_to "Logout", :controller => "account", :action => "logout"%>
<% end %>
<% if @controller_name == 'admin' %>
<% if @action_name == "list_users" %>
<%= link_to "New User", :action => "admin_user_new" %>
<%= link_to "Back", :controller => 'account', :action => 'welcome' %>
<% elsif @action_name == "edit" %>
<%= link_to "Back", controller.request.env["HTTP_REFERER"] %>
<% elsif @action_name == "admin_user_new" %>
<%= link_to "Back", :controller => "account", :action => "welcome" %>
<% elsif @action_name == 'show' %>
<%= link_to "Edit Mailing List", :action => 'edit', :id => @mailinglist %>
<%= link_to "Back", :action => 'list' %>
<% end %>
<%= link_to "Logout", :controller => "account", :action => "logout"%>
<% end %>
<% end %>