﻿$(document).ready(function() {
    swapValues = [];

    $(".Watermark").each(
                function(i) {
                    swapValues[i] = $(this).val();
                    $(this).focus(function() {
                        if ($(this).val() == swapValues[i]) {
                            $(this).removeClass("Watermark").val("")
                        }
                    }
                    ).blur(function() {
                        if ($.trim($(this).val()) == "") {
                            $(this).addClass("Watermark").val(swapValues[i])
                        }
                    })
                })

    if (typeof sIFR == "function") {

        // This is the preferred "named argument" syntax
        sIFR.replaceElement(named({ sSelector: ".h1", sFlashSrc: "/Content/dirtyheadline.swf", sWmode: "transparent", sColor: "#0F4C0A", sCase: "uppercase" }));
        sIFR.replaceElement(named({ sSelector: ".h2", sFlashSrc: "/Content/dirtyheadline.swf", sWmode: "transparent", sColor: "#4F4F4F", sBgColor: "#0F4C0A" }));
        sIFR.replaceElement(named({ sSelector: "h3", sFlashSrc: "/Content/dirtyheadline.swf", sWmode: "transparent", sColor: "#ffffff", sBgColor: "#0F4C0A" }));
        sIFR.replaceElement(named({ sSelector: ".h2_home", sFlashSrc: "/Content/dirtyheadline.swf", sWmode: "transparent", sColor: "#0F4C0A", sCase: "uppercase" }));
    };
});