Show placeholder in input type date - Javascript DOM HTML Element

Javascript examples for DOM HTML Element:Input Date

Description

Show placeholder in input type date

Demo Code

ResultView the demo in separate window

<html lang="en">
   <head> 
      <title>https://stackoverflow.com/questions/37760377/html-show-placeholder-first-in-input-type-date/37760436#37760436</title> 
   </head> 
   <body translate="no"> 
      <input type="text" id="test"> 
      <script>
      var dateofbirth="01/23/1990";
      document.getElementById('test').placeholder=dateofbirth;
    //from   ww  w  . ja v  a2s  . c om
      </script>  
   </body>
</html>

Related Tutorials