(function($) {
    $(function() {
        // IE Fixes
        if ($.browser.msie) {
            // All versions of IE
            // there is no :last-child support
            $('#primaryContent *:last-child').not('input, a, .callout, .shop-pod, .shop-pod *').addClass('last-child');
            //$('#header .navigation > li > a').append($('<span class="border-fix"></span><span class="corner top-left"></span><span class="corner top-right"></span>'));
            $('#primaryContent ul.tabs li.active').append($('<span class="corner top-left"></span><span class="corner top-right"></span>'));

            // IE 6 only
            if ($.browser.version == '6.0') {
                // there is no :first-child support
                $('#header .navigation li ul li:first-child, #footer .auxiliary div:first-child').addClass('first-child');
                // there is no support for :hover on non anchor elements
                $('#header .navigation li:has(ul), #primaryContent .product-finder .tools ul li')
					.bind('mouseover', function() { $(this).addClass('hover'); })
					.bind('mouseleave', function() { $(this).removeClass('hover'); });
                // try to fix transparent PNG's
                if (typeof DD_belatedPNG != 'undefined') {
                    DD_belatedPNG.fix('.CM_pngFix, #primaryContent .product-finder-listing .tools ul li a, #header, #primaryContent .content .section, #primaryContent .content .collection-overview, #primaryContent .content .collection-overview-divider, #primaryContent .product-finder .tools ul li a, #header .tools li.cart, #primaryContent h1.section-header, #popup.calculator h2, #popup.calculator hr, #popup a.close-button, .bottom-callout, .interface, .interface img,  #primaryContent .button, #primaryContent a.certificate, #primaryContent a.product-manual, #primaryContent .product-finder .main .stepped-content .navigation li a, #primaryContent .product-finder .main .stepped-content .navigation li.active ul li.active a, img.title, .content-pagination a, img.page-header, .scroller li.control span, #visitAgilentButton');
                }
            }
        }
        $('#primaryContent .product-finder .main tbody tr:nth-child(odd), #primaryContent .scroller li:nth-child(even), #primaryContent tbody tr:nth-child(odd), #primaryContent .shop-pod ul li:nth-child(even)').addClass('even');
        $('#header .navigation li ul li ul').each(function() {
            var myKids = $(this).children();
            if (myKids.length < 5) {
                myKids.css('width', '100%');
            }
        });
        /*
        $('input[type="text"]').each(function() {
            var me = $(this);
            if (me.val() != '') {
                me.data('original', me.val())
				  .bind('focus', function() {
				      if (me.val() == me.data('original')) {
				          me.val('');
				      }
				  })
				  .bind('blur', function() {
				      if (me.val() == '') {
				          me.val(me.data('original'));
				      }
				  });
            }
        });*/

		var $productByType = $('#primaryContent > .product-finder');
		if ($productByType.length) {
			var $step = $('.step', $productByType);
			var $imageCallout = $('img.bottom-right-callout, img.bottom-left-callout', $step);
			if ($imageCallout.length) {
				var minHeight = $imageCallout.height() - 20;
				var $columns = $('.columns', $step);
				if ($columns.length) {
					$columns.css('min-height', minHeight);
				}
				else {
					$step.css('padding-bottom', minHeight);
				}
			}
		}
    });
})(jQuery);
function CheckExternalLink(strURL) {
    
    var isInternal = (strURL.toLowerCase().indexOf("agilent.com") != -1) ? true : false;
    if (!isInternal) 
        isInternal = (strURL.toLowerCase().indexOf("http") != -1) ? false : true;
    if (!isInternal)
        var result = window.confirm('You are about to leave the Genomics website, are you sure you want to do that?');
     else 
        window.open(strURL);
    if (result)
        window.open(strURL);
    return false;
}

