How to create validation using HTML ? - Learn With Riwash

Breaking

Learn With Riwash

learn with riwash learn with riwash is the personal blog/youtube channel that provide best knowledge of software development. Here we give complate trainning of techonology as will as build software. We teach you related to web developing and programming in html,javascript,php,python,c++, c#, java programming ect. It is not a complate teaching siti like W3schools but it it a blog where we give code that help you to become better programmer.

ads

Post Top Ad

Responsive Ads Here

Post Top Ad

Responsive Ads Here

Sunday, March 25, 2018

How to create validation using HTML ?


How to create validation using HTML ?
learn with riwash
Article by Technical Riwash

Hello guys in this article i am going to tech you how to create validation.
Like if the fiels are empty then it have empty message. If email is not match then
it give error message.
   You have  a question that it is possible to make validation using HTML ?
HTML is a markup language and it use for only design.
     My answer is yes it is possibe to make/create validation using HTML.
Now, see this example

this is html tags
<html>
<head>
</head>
<body>
<form action="" method="post">

<input type="text" name="username" placeholder="username"/>
<input type="email"name="email" placeholder="email"/>
<input type="submit"name="submit" value="submit"/>
</form>

</body>
</html>

Here in example when you click in submit button it echo like email is required .
It is a validation. But in name field it not present output. what i do?
just write in required in last of input place.
<input type="text" name="username" placeholder="username" required/>
  Yes here is now error message like required.

      So this way you can make validation in HTML.
 Hi my is riwash chamlagain i am web developer/design if you want to contact me
then mail me technicalriwash@gmail.com or www.withmeriwash.com
 like comment share and subscribe.

No comments:

Post Top Ad

Responsive Ads Here