﻿
    // IF AGENTS ARE AVAILABLE:
    function agents_available() {
        document.getElementById('testLink').onclick = function() { window.open('https://admin.instantservice.com/links/5281/25736', 'custclient', 'width=500,height=320,scrollbars=0'); return false; };
        return false;
    }
    // IF AGENTS ARE NOT AVAILABLE:
    function agents_not_available() {
        document.getElementById('testLink').onclick = function() { btnChatUnavail(); return false; };
        //document.getElementById('testLink').href = 'http://www.solaxis.com/contact-us.aspx';
        return true;
    }
    function btnChatUnavail() {
        var chatpopup = document.getElementById('chatpopUp');
        chatpopup.style.display = 'block';
    }
    function closeChatUnavailBox() {
        var chatpopup = document.getElementById('chatpopUp');
        chatpopup.style.display = 'none';
    }
    function iefix(strID) {

        var ie6fix = document.getElementById(strID.toString());
        ie6fix.style.display = 'none';
        
        return false;

    }

    function chatAvailCheck() {
        document.write('<img src="http://rs.instantservice.com/resources/smartbutton/5281/25736/available.gif?' + Math.floor(Math.random() * 10001) + '" style="width:0;height:0;visibility:hidden;position:absolute;"' + ' onLoad="agents_available()" onError="agents_not_available()">');
    }

    

