×
FREE ASSISTANCE FOR THE INQUISITIVE PEOPLE
Tutorial Topics
X
softetechnologies
Date Time Number Color audio and video Tag
Email URL Phone - HTML 5
4369    Arnab De    08/05/2017

Introduction

Three most common control used in web page is

  • Email
  • URL
  • Contact no or Phone no

All of the controls have their own unique style.

Email

The Basic format of email is somename@servername.com, here ".com"may replaced by ".net", ".in" or ".something else". But in this case if we write somename@servername, then HTML cannot find any error.

softetechnologies

URL

URL Generally have one dot in middle and end with different domain name like

  1. .com
  2. .in
  3. .net
  4. .co.in
  5. .gov
  6. .edu
  7. .mil
  8. .au
  9. .pk
softetechnologies

And so on. Here a user must input the http://something.something then HTML cannot find any error.

Phone No

A phone number is just a no. It has no alphabet. General contact no in India have is a 10 digit no.

These controls are not used for data validation. For data validation we will have to use the regular expression.These three controls are similar to the normal textbox. But if we use the wrong format for the URL and email then only browser shows an error message (when we click on the submit button). But if the user uses the touch screen and iPhone 4 (iOS 4.2) and HTC Desire (Android 2.2) the different keyboard appears on selection of different controls.

Here is how the code looks like.

softetechnologies
<!DOCTYPE html>
<html> <head> <title>Contact No, Email, Website Demo</title> </head>
<body>
<form name="f1">
Contact No<input id="phone" type="tel" />
<input type="submit" />
</form>
<form name="f2">
Email<input id="email" type="email"/>
<input type="submit" />
</form>
<form name="f3">
Website<input id="website" type="url"/>
<input type="submit" />
</form>
</body>
</html>
HTML 5 Contact, eMail & Website
Contact, eMail & Website
Date Time Number Color audio and video Tag
softetechnologies
Author Details
Arnab De
I have over 16 years of experience working as an IT professional, ranging from teaching at my own institute to being a computer faculty at different leading institute across Kolkata. I also work as a web developer and designer, having worked for renowned companies and brand. Through tutorialathome, I wish to share my years of knowledge with the readers.
Enter New Comment
Comment History
No Comment Found Yet.
Sri Sri Ramakrishna Paramahamsa
One cannot be spiritual as long as one has shame, hatred, or fear.
Sri Sri Ramakrishna Paramahamsa
1195
90.61
Today So Far
Total View (Lakh)
softetechnologies
26/05/2018     55477
25/06/2018     46563
01/01/2018     44525
28/06/2017     42256
02/08/2017     41392
01/08/2017     35237
06/07/2017     34993
15/05/2017     34136
11/09/2018     32245
14/07/2017     31254
softetechnologies