﻿var imgPath = "/Portals/0/Skins/AKWRT08/images12/";

if (document.images) {
    nav_prog_on = new Image(); nav_prog_on.src = imgPath + 'nav_prog_on.png';
    nav_writers_on = new Image(); nav_writers_on.src = imgPath + 'nav_writers_on.png';
    nav_tickets_on = new Image(); nav_tickets_on.src = imgPath + 'nav_tickets_on.png';
    nav_visit_on = new Image(); nav_visit_on.src = imgPath + 'nav_visit_on.png';
    nav_news_on = new Image(); nav_news_on.src = imgPath + 'nav_news_on.png';
    nav_support_on = new Image(); nav_support_on.src = imgPath + 'nav_support_on.png';
    nav_about_on = new Image(); nav_about_on.src = imgPath + 'nav_about_on.png';
    btn_search_on = new Image(); btn_search_on.src = imgPath + 'btn-search-on.png';
}

jQuery(document).ready(
 function () {
     // main nav img swap on hover
     jQuery("#nav img.imgon").attr("src", imgPath + jQuery("#nav img.imgon").attr("name") + '_on.png');
     jQuery("#nav img").not("#nav img.imgon").hover(
        function () { jQuery(this).attr("src", imgPath + jQuery(this).attr("name") + '_on.png'); },
        function () { jQuery(this).attr("src", imgPath + jQuery(this).attr("name") + '.png') }
     );

     // Hide/show login form
     jQuery("#schedulebox").hide();
     //jQuery(".scheduleform").hide();
     jQuery(".signintoggle").click(function () { jQuery(".scheduleform").toggle(); });
     jQuery("#signupbtn").click(function () { jQuery("#schedulebox").toggle(); });


     //search button swap text with img
     jQuery("#searchbar a.search").html('').addClass('searchbutton');

 });

function getPrintButton() {
    document.write('<a href="#print" title="Print page" onclick="window.print()"><img src="' + imgPath + 'print.png" width="31" height="29" alt="Print page" hspace="10" /></a>');
}

