﻿function myWatermark(txtBox, watermark) {
    if (txtBox) {
        if (txtBox.onblur) {
            var scripting = "javascript:if(this.value==''){this.value='" + watermark + "';}";
            txtBox.onblur = scripting;
        }

        if (txtBox.onfocus) {
            var scripting = "javascript:if(this.value=='" + watermark + "'){this.value='';}";
            txtBox.onfocus = scripting;
        }

        if (txtBox.setAttribute) {
            var scripting = "javascript:if(this.value==''){this.value='" + watermark + "';}";
            txtBox.setAttribute("onblur", scripting);
        }

        if (txtBox.setAttribute) {
            var scripting = "javascript:if(this.value=='" + watermark + "'){this.value='';}";
            txtBox.setAttribute("onfocus", scripting);
        }
    }
}


///***********************************************
//* Bookmark site script- © Dynamic Drive DHTML code library (www.dynamicdrive.com)
//* This notice MUST stay intact for legal use
//* Visit Dynamic Drive at http://www.dynamicdrive.com/ for full source code
//***********************************************/

///* Modified to support Opera */
//function bookmarksite(title, url) {alert('alert the webmaster:\ngeneral.js>bookmarksite');
//    if (window.sidebar) // firefox
//        window.sidebar.addPanel(title, url, "");
//    else if (window.opera && window.print) { // opera
//        var elem = document.createElement('a');
//        elem.setAttribute('href', url);
//        elem.setAttribute('title', title);
//        elem.setAttribute('rel', 'sidebar');
//        elem.click();
//    }
//    else if (document.all)// ie
//        window.external.AddFavorite(url, title);
//}



