% if resource.errors.any? %>
<%= resource.errors.inspect %>
<% end %>
<%= form_for( resource, :as => resource_name, :url => session_path(resource_name), :html => {:class => "login-box"} ) do |f| %>
<% [:notice, :error, :alert].each do |sym| %>
<% if flash[sym].present? %>
<%= flash[sym] %>
<% flash.discard(sym) %>
<% end %>
<% end %>
<%= f.text_field :username, :placeholder => I18n.t("username", :scope => "helpers.label", :default => "Username") %>
<%= f.password_field :password, :placeholder => I18n.t("password", :scope => "helpers.label", :default => "Password") %>
<% end %>