Forum Moderators: open

Message Too Old, No Replies

Invalid email input and animation

         

toplisek

4:08 pm on Jul 17, 2020 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



I try to set an error message when there is invalid email input:
Google Material Design Input Boxes
CodePen source: [codepen.io...]

If I put invalid email inside input for email and its type email it will be moved email label over the value which is fllled in. How to manage in this case?
Need help.

NickMNS

4:17 pm on Jul 17, 2020 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Change the "type" attribute on your email input to type="email".

Don't rely on html5 form validation, it's good for UI so use it, but be sure to validate the input server side before processing it.