<div id="nav-login-content">
  <% form_tag({:controller => "account", :action=> "login"}) do %>
    <%= hidden_field_tag('back_url', CGI.escape(request.url))  %>
    <table>
      <tr>
        <td><label for="username-pulldown"><%= l(:field_login) %></label></td>
        <td><label for="password-pulldown"><%= l(:field_password) %></label></td>
      </tr>
      <tr>
        <td><%= text_field_tag 'username', nil, :tabindex => '1', :id => 'username-pulldown' %></td>
        <td><%= password_field_tag 'password', nil, :tabindex => '1', :id => 'password-pulldown' %></td>
        <td><input type="submit" name="login" value="<%=l(:button_login)%>" tabindex="1"/></td>
      </tr>
    </table>
    <div id = "optional_login_fields" style = "top = 10px; white-space:nowrap">
      <% if Setting.openid? %>
        <%= text_field_tag "openid_url", nil, :placeholder => l(:field_identity_url), :tabindex => '1' %>
      <% end %>

      <% if Setting.autologin? %>
        <label for="autologin"><%= check_box_tag 'autologin', 1, false, :tabindex => 1 %> <%= l(:label_stay_logged_in) %></label>
      <% end %>

      <% if Setting.lost_password? %>
        <%= link_to l(:label_password_lost), {:controller => 'account', :action => 'lost_password'}, :tabindex => 1 %>
      <% end %>

      <% if !User.current.logged? && Setting.self_registration? %>
        <%= "|" if Setting.lost_password? %>
         <%= link_to l(:label_register), { :controller => 'account', :action => 'register' }, :tabindex => 1 %>
      <% end %>
    </div>
  <% end %>
</div>
