Making an input type for checking valid email address in HTML

web design services - input type email - html

tutorial for web design services to make valid input type for email in html



Making an input type for checking valid email address in HTML

As a web design services, we often use input type="text" and input type="password" like below:

For text: <input type="text" name="username" size="25" maxsize="15">
For password: <input type="password" name="password">

The syntax above can be used for all types of data including email address. But how can we check whether the email address is valid or not?
If we use the code like below:

Read: Getting current total and previous one from MySQL
<input type="text" name="email" required>

we will face a trouble because the form can be submitted even with invalid email address. Off course we can use javascript or jquery to check the input value before being submitted or using PHP to check the submitted value. But we do not need to do that, because just HTML tag.

Read: Getting current total and previous one from MySQL

The solution is chahing input type becomes input type="email".
The complete code is like below:

<input type="email" name="email" required>

By doing this, the error message will show up if the vallue is invalid email address, and the form cannot be submitted.

It is very easy for web design services, right?



Related Article

Web Design Services - Best Webdesign - Best SEO Services

5 Reasons Why You Must Learn Javascript Now

Learn more about Javascript if you are passionate about web designing and programming. We can say that Javascript is an international programming language that web programmers must master. Indeed, mastering Javascript will help you to handle some web ...


7 Advantages of Using Web Programming With PHP

PHP is known as a popular web programming language in the world. It is used by millions of website developers and provides many advantages that are the main options for web developers in Indonesia. A Glimpse of PHP PHP is an open source programming ...


Restricted input type for number only by using HTML5

How to make the input type to be valid for number only? We do not need to use javascript, because we can do that easily with HTML5. Let say we want to make an input type for temperature with the following rule: minimum 30o and maximum 50o, but allow ...


We create RESPONSIVE WEBSITE

Responsive web is special program code, so the website can be read in all devices. It is very suitable for better page rank in search engine like google

graphic design in indonesia

Website Design in Indonesia

Graphic Design in Indonesia

Contact

+628113638531 / +628113865464

info@tatamedia.com

Webdesigner in Indonesia

Videographer in Bali

Office

Tatamedia Solusindo Surabaya

Dekkophotography Bali

Fine Art Photography in Bali

Web Design

Support

Send your request to

info@tatamedia.com