$(function () {

    $("input[type=text].masked").each(function (idx) {

        $(this).val($(this).attr("title"));

        $(this).bind("focus", function () {

            if ($(this).val() == $(this).attr("title")) {
                $(this).val("");
                $(this).addClass("active");
            }

        });

        $(this).bind("blur", function () {

            if ($(this).val() == "") {
                $(this).val($(this).attr("title"));
                $(this).removeClass("active");
            }

        });

    });

});
