WAI / XHTML Valid Input Watermarks for Mootools

Just refactored the input watermarking script, of course it is still XHTML 1.0 transitional and WCAG priority 1,2 valid.

JavaScript:

Usage: Just put value on you inputs and use class=”watermark”

As usual example

WAI / XHTML Valid Input Fields Watermark

Have you ever wondered how people put text in their input fields and when you click on it, it disappears. This process is called input watermarking.

Bellow is the JavaScript I’m using on my sites. It is XHTML 1.0 transitional and WCAG priority 1,2 valid.

Usage: Just fill the array with the IDs and the values. Instead of IDs you can use names

Input Watermark Example page