|
Plug-in PHP: 100 Power Solutions By Robin Nixon (McGraw Hill 2010, ISBN 978-0071666596) Home | About | Buy It |
Chapter 11: Plug-in 88 - Input PromptSometimes you can make the life of your users easier when filling web forms by placing a prompt for what is required in the form field itself. Obviously you only want to do that when the field is blank, otherwise, if a field has a value then that's likely to be what the user wanted to enter. Using this plug-in, whenever you create a form <input> element you can specify such a prompt, and it will only appear when the field contains no input. |