function printUnica()
{
    ntptEventTag('ev=internal_links&evdetail=Print&evloc=Header');
    window.print();
}

(function($) {
    function confirm(redirect_url, popupType) {
        $(popupType).modal({
            overlayId: 'confirm-modal-overlay',
            containerId: 'confirm-modal-container',
            autoPosition: true,
            opacity: 85,
            onShow: function(dialog) {
                var modal = this;
                $('.yes_confirm', popupType).click(function(e) {
                    e.preventDefault();
                    $.modal.close();
                    window.open(redirect_url, "_blank");
                    //window.location.href = redirect_url;
                });
                $('.closePopNo', popupType).click(function(e) {
                    e.preventDefault();
                    $.modal.close();
                    if($('.modal-popup').css("display") == "block") {
                        $('img', '.modal-popup').css('visibility', 'visible');
                    }
                });
                /*$('.closePopUp', popupType).click(function (e) {
                e.preventDefault();	
                var redirect_url = $(this).attr('href');
                window.location.href = redirect_url;				
                $.modal.close();
                $('img','.modal-popup').css('visibility','visible');
                });*/
            }
        });
    }

    jQuery(function($) {
        var $modalVar = $('a.confirm-modal'),
			$modalVarFooter = $('a.confirm-modal-foot'),
			modal_html = "<div class='modal-popup'><div class='popupContainer'><img src='/images/img-urleaving.gif' align='You Are Now Leaving' title='You Are Now Leaving' class='img_top' /><p class='normal'>You are now leaving  <a onclick=\"ntptEventTag('ev=internal_links&evdetail=PadFactsSite&evloc=Interstitial');\" href='http://www.padfacts.com' class='closePopUp' target='_blank'>www.padfacts.com</a>.You will be taken to a branded pharmaceutical site to learn about a treatment option. This site is sponsored by the Bristol-Myers Squibb/Sanofi Pharmaceuticals Partnership</p><a href='javascript:void(0)' class='closePopNo'><img onclick=\"ntptEventTag('ev=internal_links&evdetail=ReturnToPadFacts&evloc=Interstitial');\" src='/images/button_return.gif' title='return' width='219' class='img_return' /></a><a href='javascript:void(0)' class='img_proceed yes_confirm' target='_blank'><img onclick=\"ntptEventTag('ev=internal_links&evdetail=Proceed&evloc=Interstitial');\" src='/images/button_proceed.gif' title='proceed' width='96'  /></a></div></div>";
			//modal_html_footer = "<div class='modal-popup-foot'><div class='popupContainer'><img src='images/img-urleaving.gif' title='You Are Now Leaving' class='img_top' /><p class='normal'>You are now leaving <a href='http://www.padfacts.com' class='closePopUp'>www.padfacts.com</a>. You will be taken to a branded pharmaceutical site to learn about a treatment option. This site is sponsored by the Bristol-Myers Squibb/Sanofi Pharmaceuticals Partnership</p><a href='javascript:void(0)' class='closePopNo'><img src='images/button_return.gif' title='return' width='219' class='img_return' /></a><a href='javascript:void(0)' class='img_proceed yes_confirm'><img src='images/button_proceed.gif' title='proceed' width='96' /></a></div></div>";
        if ($modalVar.length) {
            if(jQuery('.modal-popup').length == 0){
                jQuery(modal_html).appendTo('body');
            }
            $modalVar.click(function(e) {
                e.preventDefault();
                var redirect_url = $(this).attr('href');
                confirm(redirect_url, '.modal-popup');
            });
        }
       /* if ($modalVarFooter.length) {
        $modalVarFooter.click(function (e) {
        e.preventDefault();
        var redirect_url = $(this).attr('href');			
        confirm(redirect_url,'.modal-popup-foot');			
        });		
        }*/
        
        //jQuery(modal_html_footer).appendTo('body');	
        
        var $modalVarnew = $('a.confirm-modal-new'),
            modal_html_new = "<div class='modal-popup1'><div class='popupContainer'><img src='/images/img-urleaving.gif' align='You Are Now Leaving' title='You Are Now Leaving' class='img_top' /><p class='normal'>This site may provide links or references to other Websites not affiliated with the Bristol-Myers Squibb/Sanofi Pharmaceuticals Partnership. The Bristol-Myers Squibb/Sanofi Pharmaceuticals Partnership is not responsible for the content of such other sites and shall not be liable for any damages or injury arising from users' access to such sites. Links to other sites are provided only as a convenience to users of our site.</p><p><strong>Do you want to leave this site?</strong></p><a href='javascript:void(0)' class=''><img src='/images/button_return.gif' title='return' width='219' class='img_return' /></a><a href='javascript:void(0)' class='img_proceed yes_confirm' target='_blank'><img src='/images/button_proceed.gif' title='proceed' width='96'  /></a></div></div>'";

        if ($modalVarnew.length) {if(jQuery('.modal-popup1').length == 0){
                jQuery(modal_html_new).appendTo('body');
            }

            $modalVarnew.click(function(e) {
                e.preventDefault();
                var redirect_url1 = $(this).attr('href');
                confirm(redirect_url1, '.modal-popup1');

            });
        }	
    });
} (jQuery))

jQuery(document).ready(function() {
    var currUrl = window.location.pathname.substr(window.location.pathname.lastIndexOf("/") + 1, window.location.pathname.length),
                                fname = currUrl.split('.', currUrl.length);
    switch (fname[0]) {

        case 'pad-test':
        case 'early-detection':
        case 'getting-diagnosed': className = 'tab2';
            break;

        case 'development':
        case 'symptoms':
        case 'risk-factors':
        case 'doctor':    
        case 'what-is-pad': className = "tab1";
            break;
        case 'pad-medications': className = "tab3";
            break;

        case 'nutrition':
        case 'quit-smoking':
        case 'exercise':    
        case 'pad-lifestyle-changes': className = "tab4";
            break;
        case 'pad-resources':    
        case 'terms': className = "tab5";
            break;
        default: className = null;
    }
    if (className !== null) {
        classNameActive = className + "_active";
        className = "." + className;
        jQuery(className, '.spritesTab').addClass(classNameActive);
    }
});           

