What are potential issues with using the button element in PHP forms?

One potential issue with using the button element in PHP forms is that it may not submit the form data properly, especially when using the button element with type="button" instead of type="submit". To solve this issue, ensure that the button element has the type attribute set to "submit" so that it triggers form submission.

<form method="post">
    <input type="text" name="username" placeholder="Username">
    <input type="password" name="password" placeholder="Password">
    <button type="submit" name="submit">Submit</button>
</form>