﻿// JScript File
// JScript File
jQuery.noConflict();
jQuery(document).ready(function() {
    //Check if this browser is IE6
    if ( document.all && !window.opera && !window.XMLHttpRequest && jQuery.browser.msie ) 
        {var isIE6 = true;}
    else
        { var isIE6 = false;} ;
    jQuery.browser.msie6 = isIE6;
    jQuery('span.check_box input:checkbox').click(function() {
        if (jQuery(this).is(':checked')) {
            var sCategory = jQuery(this).parents().find('div.bordered h1.categoryheadline span').html();
            var needle = /_cbl_(\d+)_/g;
            jQuery(this).attr('id').match(needle);
            var iFacetId = RegExp.$1;
            var sTypeFinder = 'td.category_' + jQuery.query.get('id') + '_facet_' + iFacetId + ' h3.facet_name';
            var sAction = jQuery(this).parents().find(sTypeFinder).text();
            var sLabel = jQuery(this).parent().find('label').text();
            pageTracker._trackEvent(sCategory, sAction, sLabel, 0);
            if (g_isIntermediate) {
               if (isNumeric(jQuery(this).parent().attr('title'))) {
                    window.location.href = "?id=" + jQuery(this).parent().attr('title');
               } else {
                    window.location.href = jQuery(this).parent().attr('title');
               }
            }
        }
    });

});
function isNumeric(val) {
    if (isNaN(parseFloat(val))) {
          return false;
     }
     return true;
}

