$(document).ready(function() {

    // Define what happens when the textbox comes under focus
    // Remove the watermark class and clear the box
    $("#newslettertxt").focus(function() {

        $(this).filter(function() {

            // We only want this to apply if there's not 
            // something actually entered
            return $(this).val() == "" || $(this).val() == "Type your email here"

        }).addClass("watermarkOn").val("");

    });

    // Define what happens when the textbox loses focus
    // Add the watermark class and default text
    $("#newslettertxt").blur(function() {

        $(this).filter(function() {

            // We only want this to apply if there's not
            // something actually entered
            return $(this).val() == ""

        }).addClass("watermarkOn").val("Type your email here");

    });

});