Articles → HTML 5 → Placeholder Attribute In Html5

Placeholder Attribute In Html5






Purpose





Syntax


<input type="text" placeholder=" " />



Example


<!DOCTYPE html>
<html lang="en">
   <head>
      <title></title>
   </head>
   <body>
      <form>
         <input type="text" placeholder="Enter your name here" />
      </form>
   </body>
</html>

Try It


Output


Picture showing the output of Placeholder attribute  in HTML5
Click to Enlarge


Browser Support


Internet ExplorerFirefoxChromeSafariOperaEdge
10.04.010.05.011.0Yes



Posted By  -  Karan Gupta
 
Posted On  -  Wednesday, November 21, 2018

Query/Feedback


Your Email Id
 
Subject
 
Query/FeedbackCharacters remaining 250