history.navigationMode = 2;
$(window).unload(function() {$('body').val('');});

function submit1(e, val1) {
    if (e.keyCode == 13) {
        document.getElementById(val1).click(); return true;
    }

}
$(document).unload(function () { document.body.innerHTML = ''; });

$(document).ready(function () {

    if($('h1').html() && $('h1').first().html().indexOf('Radius Geographic Information Systems')!=-1) {
	$('h1').first().css('font-size','35px');
    }

    if($('.dnnCPHeader .dnnCPHNav').first().hasClass('dnnCPHNav') && !$('.logOut').first().html()) {
	$('.dnnCPHeader .dnnCPHNav').first().prepend('<a class="logOut" href="/logoff.aspx">Logout</a>');
    }

    $('.content_inner2').css('minHeight', ( Math.round($(window).height() ) - 373)+'px');

    if($('.topTabs').html()) {
	$('body').css('background', '#939698');
	if($(window).height() > 985) $('#content_div').css('minHeight', ( Math.round($(window).height() ) - 275)+'px');

    }

    $('.tab1').click(function () {
        $('.topTabs a').removeClass('selected');
        $(this).addClass('selected');
        $('.b').hide();
        $('.b:eq(0)').show();
        return false;
    });
    $('.tab2').click(function () {
        $('.topTabs a').removeClass('selected');
        $(this).addClass('selected');
        $('.b').hide();
        $('.b:eq(1)').show();
        return false;
    });
    $('.tab3').click(function () {
        $('.topTabs a').removeClass('selected');
        $(this).addClass('selected');
        $('.b').hide();
        $('.b:eq(2)').show();
        return false;
    });

    $('#emailNewsletter').val('Your Email Address');
    $('#emailNewsletter').focus(function () { if ($('#emailNewsletter').val() == 'Your Email Address') $('#emailNewsletter').val(''); });
    $('#emailNewsletter').blur(function () { if (!$('#emailNewsletter').val()) $('#emailNewsletter').val('Your Email Address'); });


    $('input').attr('autocomplete', 'off');

    $('#menu a').each(function(index) {
     if ( $(this).attr('href').replace(/.*\//,'')==location.href.replace(/.*\//,'') ) $(this).addClass('selected');
    });
     
    if($('div#content_div_inner2 div.content_inner2 div#dnn_ContentPane.content_inner2_l2 div.DnnModule div#dnn_ctr456_ContentPane div#dnn_ctr456_ModuleContent.DNNModuleContent p').html()) {
     var h = $('div#content_div_inner2 div.content_inner2 div#dnn_ContentPane.content_inner2_l2 div.DnnModule div#dnn_ctr456_ContentPane div#dnn_ctr456_ModuleContent.DNNModuleContent p').first().html();
     h = h.replace('Radius Information Technology (Radius IT)','<a href="./RADIUSIT.aspx">Radius Information Technology (Radius IT)</a>');
     h = h.replace('Radius Security Services (Radius Security)','<a href="./RADIUSSECURITY.aspx">Radius Security Services (Radius Security)</a>');
     h = h.replace('Radius Geospatial Information Systems (Radius GIS)','<a href="./RADIUSGIS.aspx">Radius Geospatial Information Systems (Radius GIS)</a>');
     h = h.replace('Radius Geographic Information Systems (Radius GIS)','<a href="./RADIUSGIS.aspx">Radius Geographic Information Systems (Radius GIS)</a>');

     $('div#content_div_inner2 div.content_inner2 div#dnn_ContentPane.content_inner2_l2 div.DnnModule div#dnn_ctr456_ContentPane div#dnn_ctr456_ModuleContent.DNNModuleContent p').first().html(h);
    }

});

