﻿$(document).ready(function() {

$(".RemoveWaterType").each(function() {
    $tb = $(this);
   $tb.removeClass("water");
   $tb.removeClass("watertype");
});

    $(".water").each(function() {
        $tb = $(this);
        if ($tb.val() != this.title) {
            $tb.removeClass("water");
        } 
    });

    $(".watertype").each(function() {
        $tb = $(this);
        if ($tb.val().length <= 0 ){
            $tb.val(this.title);
            $tb.addClass("water");
        }
    });
    
    $(".watertype").focus(function() {       
        $tb = $(this);
        if ($tb.val() == this.title) {
            $tb.val("");
            $tb.removeClass("water");
            
        }
    });
    
     $(".watertype").blur(function() {
        $tb = $(this);
        if ($.trim($tb.val()) == "") {       
            $tb.val(this.title);
            $tb.addClass("water");
        }
    });
    
    $(".water").focus(function() {
        $tb = $(this);
        if ($tb.val() == this.title) {
            $tb.val("");
            $tb.removeClass("water");
            
        }
    });

    $(".water").blur(function() {
        $tb = $(this);
        if ($.trim($tb.val()) == "") {
            $tb.val(this.title);
            $tb.addClass("water");
        }
    });
});


