﻿
//Main function , assigns behaiviors to different elements , when document is ready
$(document).ready(function () {
    $(".regular").mouseover( function (e) {
        $(this).css("color", "#FEF200");
    }).mouseout(function (e) { $(this).css("color", "#FFFFFF"); });

    var tempValue;
    $('.subscribeinput').focusin(function (e) {
        tempValue = $(this).val();
        $(this).val("");
    }).focusout(function (e) {
        if ($(this).val() == '' || $(this).val() == tempValue || $(this).val() == 'שם' || $(this).val() == 'דואר אלקטרוני') { $(this).val(tempValue) }
    });


})

function setHomepage(title, url) {

    if (document.all) {
        document.body.style.behavior = 'url(#default#homepage)';
        document.body.setHomePage(url);

    }
    else if (window.sidebar) {
        if (window.netscape) {
            try {
                netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
            }
            catch (e) {
                alert("this action was aviod by your browser，if you want to enable，please enter about:config in your address line,and change the value of signed.applets.codebase_principal_support to true");

            }
        }
        var prefs = Components.classes['@mozilla.org/preferences-service;1'].getService(Components.interfaces.nsIPrefBranch);
        prefs.setCharPref('browser.startup.homepage', url);
    }
}




/***********************************************
* Bookmark site script- © Dynamic Drive DHTML code library (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit Dynamic Drive at https://www.dynamicdrive.com/ for full source code
***********************************************/

/* Modified to support Opera */
function bookmarksite(title, url) {

    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);
}


