button + link help and

Asked

Viewed 38 times

-2

to make a site for a work in the course, I need to create a login or registration whatever but when I put a button (button/header/input) I am using "required" and the pass button n asks to fill (Note: are commented pq was testing )

Imagem Do Codigo

  • 1

    1) Don’t put your code as an image, the site has source code support, just do the [tour], read the [Ask] guide and access the [help]; 2) Always use informational titles in the question; the title "button + link help ae" does not make clear what is asked; 3) Whenever you ask elaborate a [mcve] demonstrating the problem so that we can reproduce it; post an excerpt of code that is supposedly in error but comment on it makes no sense.

  • 1

    About the problem itself, it doesn’t make sense that you have one <a> within a <button>; the first serves for navigation, the second to perform an action. As you pressed the first, you will be navigating between pages, not submitting a form, so the required is not considered.

  • 1

    @Leonardonegrão, I reversed its edition for misrepresenting the original question.

  • @Andersoncarloswoss, I really had some doubts, because my edition brought the answer rs

  • 1

    @Leonardonegrão "Descaracteriza" basically because the problem mentioned in the question is precisely in the commented parts of the code, so it does not make sense to remove them.

  • @Andersoncarloswoss, got it, thanks for the explanation

Show 1 more comment

1 answer

-1


I did the editing of your code (always ask with relevant snippets of code written) and just by rewriting your code has already worked:

<div class="section">
    <h2>Login</h2>
    <form method="get" action="">
    <input type="email" class="Login" name="Email" placeholder="Email" required><br />
    <input type="password" class="Login" name="Senha" placeholder="Senha" required><br />
    <input type="submit" class="button"">
    </form>
    </div>

Watch out for using a clean, standardized code, for example, the Email field in the name attribute in your example is uppercase and "password" in the next field is lowercase.

Good luck

Browser other questions tagged

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