$(document).ready(function () {
    $("#link_mobile").click(function () {
        if (checkUnsavedData()) {
            if(GMobileModeUrl && GMobileModeUrl.length > 0){
                var url = GMobileModeUrl + encodeURI(window.location.href.split("&").join("_@nd_"));
                window.location.href = url;
            }
        }
    });

    $("#btn-toggle-header-a").click(function () {
        if (checkUnsavedData()) {
            $urlParam = ($.cookie('hideheader') == 1 ? 0 : 1);
            $.ajax({
                url: "hideheader.php?hheader=" + $urlParam,
                success: function (response) {
                    location.reload();
                }
            });
        }
    });
});


