How can I make an input box have that faint grey text which disappears as soon as you type something into the box.
eg. exists in the ‘Title’ input box when you go to ask a question in the form of ‘Is there an R function for finding the index element in a vector.’.
What you're looking for is called a placeholder
. Here is an example:
<input type="text" placeholder="Type something here">
Here is another example with textarea
:
<textarea rows="4" cols="50" placeholder="Describe yourself here..."></textarea>