Dave's Brain

Browse - Programming Tips - How can I have an in-place prompt for an input type=text field

Date: 2014jun26
Language: html
Keywords: inplace

Q.  How can I have an in-place prompt for an <input type=text> field
as you see on phones?

A.  Use placeholder= for example:

<input name="surname" placeholder="Your last name">

Add a comment

Sign in to add a comment
Copyright © 2008-2017, dave - Code samples on Dave's Brain is licensed under the Creative Commons Attribution 2.5 License. However other material, including English text has all rights reserved.