JSFiddle - React, Tailwind, and code Playground
by Nick Craver
HTML
<link rel="stylesheet" href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/dot-luv/jquery-ui.css">
<div class="padtop8 box2withbtn">
<div class="inbox3full">
<div class="threeinbg"><input name="ctl00$ctl00$cphBody$midbox$fvInsert$txtDepartmentName" type="text" id="ctl00_ctl00_cphBody_midbox_fvInsert_txtDepartmentName" title="Type your Department Name" class="threein water" /></div>
</div>
<div class="inbox3full">
<div class="threeinbg"><input name="ctl00$ctl00$cphBody$midbox$fvInsert$txtSortOrder" type="text" id="ctl00_ctl00_cphBody_midbox_fvInsert_txtSortOrder" title="Type your Sort Order" class="threein water" /></div>
</div>
<div class="inboxbutton padtop8">
<input type="image" name="ctl00$ctl00$cphBody$midbox$fvInsert$btnInsert" id="ctl00_ctl00_cphBody_midbox_fvInsert_btnInsert" Text="Insert" src="../images/save.gif" alt="Save" style="border-width:0px;" />
<input type="image" name="ctl00$ctl00$cphBody$midbox$fvInsert$btnCancel" id="ctl00_ctl00_cphBody_midbox_fvInsert_btnCancel" Text="Cancel" src="../images/cancle.gif" alt="Cancel" style="border-width:0px;" />
</div>
<div class="clear"></div>
</div>
CSS
.water { color: #aaa; }
JavaScript
$(".water").addClass('watermark');
$(".watermark").live('focus', function() {
$tb = $(this);
if ($tb.val() == this.title) {
$tb.val("");
$tb.removeClass("water");
}
}).live('blur', function() {
$tb = $(this);
if ($.trim($tb.val()) == "") {
$tb.val(this.title);
$tb.addClass("water");
}
}).blur();