Html5 - W3C validation errors - Rails(Embedded Ruby)

108 views Asked by At

Kindly guide me to solve these errors in sign up and login views

<div class="jumbotronsignup">
  <div class="container">        


    <div class="row">

      <div class="col-md-4 col-md-offset-4 labelcolor">

      <h3>SIGN UP</h3>

        <%= form_for(@user) do |f| %>

          <%= render 'shared/error_messages', object: f.object %>

          <%= f.label :name %>
          <%= f.text_field :name, autofocus: true , class: 'form-control' %>

          <%= f.label :email %>
          <%= f.text_field :email, class: 'form-control' %>

          <%= f.label :password %>
          <%= f.password_field :password, autocomplete: "off", class: 'form-control' %>

          <%= f.label :password_confirmation, "Password Confirmation" %>
          <%= f.password_field :password_confirmation, autocomplete: "off", class: 'form-control' %>

          <div>
          <%= f.label :is_female, "Gender" %>
          <%= f.select :is_female,  User::GENDER_TYPES , {}, { :class => 'form-control' } %>
          </div>


          <div>
          <%= f.label :date_of_birth, :class=>'singleline' %>
          <%= f.date_select :date_of_birth, { :start_year => 1920, :end_year => 2010 }, :class => 'form-control date-select datetest' %>
          </div>

          <div>
            <%= f.label :avatar , "Profile Picture" %>
            <%= f.file_field :avatar, accept: 'image/jpeg,image/gif,image/png,image/tiff', class: 'form-control' %>
          </div>

          <div class="row text-center">
          <%= f.submit "Create my account", class: "btn mybtn-primary btn-lg" %>
          </div>

        <% end %>

      </div> 

    </div>    


  </div><!-- end of container -->

</div><!-- end of jumbotron --> 

How can I solve this error?

enter image description here

And this is my login page

<div class="jumbotronsignup">
  <div class="container">        


    <div class="row">

      <div class="col-md-4 col-md-offset-4 labelcolor">

      <h3>LOG IN</h3>

        <%= form_for(:session, url: login_path) do |f| %>

          <%= f.label :email %>
          <%= f.text_field :email, class: 'form-control' %>

          <%= f.label :password %>
          <%= link_to "(forgot password)", new_password_reset_path %>
          <%= f.password_field :password, class: 'form-control' %>

          <%= f.label :remember_me, class: "checkbox inline" do %>
            <%= f.check_box :remember_me %>
            <span>Remember me on this computer</span>
          <% end %>

          <div class="row text-center">
          <%= f.submit "Log in", class: "btn mybtn-primary btn-lg" %>
          <p>New user? <%= link_to "Sign up now!", signup_path %></p>
          </div>

        <% end %>


      </div> 

    </div>    


  </div><!-- end of container -->
</div><!-- end of jumbotron --> 

enter image description here

0

There are 0 answers