﻿//var rootFolder = "../../";
var rootFolder = "";
$(document).ready(
function () {
    $(window).resize(function () { PlaceMasterDivs(); localPlaceMasterDivs(); });
    $(window).scroll(function () { PlaceMasterDivs(); localPlaceMasterDivs(); });
    $('#divOverlay').hide();
    $('#divTop').hide();
    textBoxEvents();
    PlaceMasterDivs();
    localPlaceMasterDivs();
    InitLogin();
    ShowPage();
    /*$('#divContent').dropShadow({
        left: 1,
        top: -1,
        blur: 5,
        opacity: .3
    });*/
});

function ShowPage() {
    PlaceMasterDivs();
    $('#divRoot').css('visibility', 'visible');
    $('#divRoot').hide();
    $('#divRoot').fadeIn('slow');
}

function textBoxEvents() {
    $('#txtbxName').keydown(function () { pbRequestInfo(event); });
    $('#txtbxEmail').keydown(function () { pbRequestInfo(event); });
    $('#txtbxTelephone').keydown(function () { pbRequestInfo(event); });
    $('#txtbxWebsite').keydown(function () { pbRequestInfo(event); });
}

function pbRequestInfo(event) {
    if (event.keyCode == 13) {
        //event.preventDefault();
        //__doPostBack('btnLogin', '');
    
    }
}

function localPlaceMasterDivs() {
    if ($('#divForContent').height() + $('#divHeader').height() + $('#divFooter').height() < $(window).height()) {
        $('#divForContent').css('height', $(window).height() - $('#divHeader').height() + $('#divFooter').height());
    }

    if ($('#divInfo').height() + $('#divHeader').height() + $('#divFooter').height() < $(window).height()) {
        $('#divInfo').css('height', $(window).height() - $('#divHeader').height() + $('#divFooter').height());
    }
}
