I’m having a problem loading the page she goes straight to the footer

Asked

Viewed 242 times

0

When opening the page on the localhost it goes straight to the footer: inserir a descrição da imagem aqui

And it doesn’t start in the headline:

inserir a descrição da imagem aqui

The problem is in the form, but I have no idea of pq.. ] code:

 <form id="contact" action="mail_send.php" method="post">
    <h3>Precisa de Ajuda?</h3>
    <h4>Entraremos em contato em 24 horas úteis.</h4>
    <fieldset>
      <input placeholder="Digite seu nome" type="text" tabindex="1" required autofocus>
    </fieldset>
    <fieldset>
      <input placeholder="Digite seu email" type="email" tabindex="2" required>
    </fieldset>
    <fieldset>
      <input placeholder="Deixe o seu numero (Opicional)" type="tel" tabindex="3" required>
    </fieldset>
    <fieldset>
      <textarea placeholder="Digite sua mensagem ...." tabindex="5" required></textarea>
    </fieldset>
    <fieldset>
      <button name="submit" type="submit" id="contact-submit" data-submit="...Enviando">Enviar</button>
    </fieldset>
  </form>

And when I give F5 on the page she does not go to the top of the page she remains fixed is normal?

1 answer

1


Felipe, the problem is you’re activating the autofocus in the input, making the browser understand that that field is activated by the user, making the page scroll straight to where the focus is, literally. Just remove that your problem is solved.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.