// JavaScript Document function openSendMap(url,title){ window.open("/en/consumer/get-it/find-a-clinician/send-map.asp?pageToSend=" + url, "sendMap", "width=460,height=500,location=no,menubar=no,toolbar=no,resizable=no,scrollbars=no"); void(0); } function zebra(){ var visible_element = new Array(); $('#block01 table#compare tr').not('.heading,#implanon').each(function(){ // don't check for :visible, breaks on table rows in ie6 if(!($(this).is(':hidden'))){ visible_element.push($(this)); } }); for(var i=0;i

Clinician Details

'); $('#locator_results .result.search_result .info,#locator_results .result.search_result .hours').clone().appendTo('#block02 .pad.spot .clinician_details'); } function openConsumerTour(){ window.open('/en/consumer/productTour.asp', 'homepageChart', 'width=950,height=580,location=no,menubar=no,toolbar=no,resizable=no,scrollbars=no'); } $(document).ready(function() { //homepage spotlight rollovers $('.homespot').hover( function(){$(this).addClass('active');}, function(){$(this).removeClass('active');} ); //print dialog $('img.printicon, .util .print').click(function(e){ e.preventDefault(); self.print(); }); $('img.compareprint').click(function(){ var printpopup = window.open('','comparepopup','toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=yes, resizable=yes, copyhistory=no, width=650, height=530'); var text = ''; var compare = $('#comparewrapper').html(); var html = ''; html += '

close
Print-friendly comparator chart

'; html += compare; html += ''; html += '

print

'; html += ''; printpopup.document.open(); printpopup.document.write(html); printpopup.document.close(); }); $('.pagefold img.print').click(function(){ var printpopup = window.open('','printfoldpopup','toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=yes, resizable=yes, copyhistory=no, width=650, height=530'); var text = ''; var pagefold = $('#pagefoldwrapper').html(); var html = ''; html += '

close
Questions about Implanon®

'; html += pagefold; html += ''; html += '

print

'; html += ''; printpopup.document.open(); printpopup.document.write(html); printpopup.document.close(); }) $('.popup .close').click(function(){ self.close(); }); if($('.popup.printfriendly').length >= 1){ self.print(); } //set selected elements in nav if($('#navigation ul li.active')){ $('#navigation ul li.active').parent('ul').parent('li').addClass('active'); } //set rollover state for primary nav and sub-nav $('#navigation > li a,#navigation > li > ul > li > a').hover( function(){//roll on $(this).parent().not('.active').addClass('hover'); }, function(){//roll off $(this).parent().removeClass('hover'); } ); //set left column photo and content placement if($('#block02 .pad').find(':first-child').is('.spotlight')){ $('#block02 .pad').addClass('spot'); } else{ if(!$('#page').hasClass('home')){ $('#mastheadphoto').addClass('short'); } } //build compare checkbox elements $($('#block01 table#compare tr').not('#implanon,.heading').find('td:first-child').get().reverse()).each(function(){ var compare_form = $('#compare_list'); var el = $(this).parent().attr('id') + '_check'; compare_form.prepend('

'); }); //show and hide contraception options $('#compare_list .compare_check').live('click',function(){ //based on clicked element, remove '_check' from id string var el=$(this).attr('id'); el=el.substring(0,el.indexOf('_check')); //compare all if($(this).attr('id')=='compare_all'){ if(!$(this).hasClass('on')){ $(this).siblings().andSelf().each(function(){ if(!$(this).hasClass('.on')){ $(this).addClass('on'); } }); $('#block01 table#compare tr').not('.heading,#implanon').each(function(){ $(this).removeClass('hidden'); $(this).children('td').fadeIn(500); zebra(); }); $('p.vaginal_ring.disclaimer').removeClass('hidden'); } else if($(this).hasClass('on')){ $(this).siblings().andSelf().each(function(){ if($(this).hasClass('.on')){ $(this).removeClass('on'); } }); $('#block01 table#compare tr').not('.heading,#implanon').each(function(){ $(this).children('td').fadeOut(500,function(){ $(this).parent().addClass('hidden'); zebra(); $('p.vaginal_ring.disclaimer').addClass('hidden'); }); }); } } //compare individual else{ $(this).toggleClass('on'); var x = $('body').find('#'+el); if($(x).hasClass('hidden')){ $(x).removeClass('hidden'); $(x).children('td').fadeIn(500); zebra(); if(x.attr('id') == 'ring'){ $('p.vaginal_ring.disclaimer').removeClass('hidden'); } } else{ $(x).children('td').fadeOut(500,function(){ $(x).addClass('hidden'); zebra(); if(x.attr('id') == 'ring'){ $('p.vaginal_ring.disclaimer').addClass('hidden'); } }); } //uncheck 'compare all' checkmark $(this).siblings().each(function(){ if($(this).attr('id')=='compare_all'){ $(this).removeClass('on'); } }); } }); //faq if($('#block01 .faq_selector').length > 0){ $('#block02 .pad').prepend($('.faq_selector')); $('#block01 #faq_selector').remove(); $('#block02 .pad').addClass('faq'); $('#mastheadphoto').addClass('short'); $('#block02 .pad').removeClass('spot'); $('#block02 .faq_selector .head:first-child').next().slideDown(); $('#block02 .faq_selector .head:first-child').addClass('on'); } $('.faq_selector .head').click(function() { if($(this).hasClass('on')){ $(this).next().slideUp('fast'); $(this).removeClass('on'); } else{ $(this).next().slideDown('fast'); $('.faq_selector .head.on').each(function(){ $(this).next().slideUp(); $(this).removeClass('on'); }); $(this).addClass('on'); } }); $('.faq_selector .questiongroup a').click(function(e) { e.preventDefault(); if(!($("#qaIntro").is(':hidden'))){ $("#qaIntro").addClass('hidden'); } $('.faq_selector .questiongroup a').each(function(){ $(this).removeClass('selected'); if($(this).prev().is('a')){ $(this).prev('a').find('span.rulebottom').removeClass('mod'); } }); if(!$(this).hasClass('selected')){ $(this).addClass('selected'); if($(this).prev().is('a')){ $(this).prev('a').find('span.rulebottom').addClass('mod'); } } var selectedId = $(this).attr('href'); $('#faq_answers .answer').hide(); $('#faq_answers').find(selectedId).show(); }); //clinic locator (function for duplicated form exists below) $('form#locator select#searchType').change(function(){ var zip = $('form#locator #ZipCode_container'); var area = $('form#locator #Area_container'); var state = $('form#locator #State_container'); var clinicName = $('form#locator #ClinicianName_container'); var clinic = $('form#locator #ClinicName_container'); var button = $('form#locator #submit_container'); var pageNum = $('form#locator #submit_container #locatorPageNum'); pageNum.val('1'); zip.hide(); area.hide(); state.hide(); clinicName.hide(); clinic.hide(); button.hide(); if($(this).val()=='0'){ //state state.show(); button.show(); } if($(this).val()=='1'){ //practice name clinic.show(); button.show(); } if($(this).val()=='2'){ //zip code zip.show(); area.show(); button.show(); } if($(this).val()=='3'){ //clinician last name clinicName.show(); button.show(); } }); //clinic locator duplicate $('form#locator_dup select#searchType_dup').change(function(){ var zip = $('form#locator_dup #ZipCode_container_dup'); var area = $('form#locator_dup #Area_container_dup'); var state = $('form#locator_dup #State_container_dup'); var clinicName = $('form#locator_dup #ClinicianName_container_dup'); var clinic = $('form#locator_dup #ClinicName_container_dup'); var button = $('form#locator_dup #submit_container_dup'); zip.hide(); area.hide(); state.hide(); clinicName.hide(); clinic.hide(); button.hide(); if($(this).val()=='0'){ //state state.show(); button.show(); } if($(this).val()=='1'){ //practice name clinic.show(); button.show(); } if($(this).val()=='2'){ //zip code zip.show(); area.show(); button.show(); } if($(this).val()=='3'){ //clinician last name clinicName.show(); button.show(); } }); $('#block02 .spotlight').mouseover(function(){ $(this).addClass('spotlight-on'); }); $('#block02 .spotlight').mouseout(function(){ $(this).removeClass('spotlight-on'); }); $('#locator_results .result:even').addClass('odd'); if($('#locator_results .search_result').length >= 1){ formatLocatorResult(); } $('#print a').click(function(e){ e.preventDefault(); self.print(); }) $('#print').qtip({ content: 'print', position: { corner: { target: 'bottomMiddle', tooltip: 'topMiddle' }, adjust: { x: 0, y: 10 } }, style: { width: 45, padding: 0, background: '#e8e2e2', color: '#7b7b7b', textAlign: 'center', border: { width: 1, radius: 3, color: '#e8e2e2' } } }) //input type=image rollovers //Request for training back button $('#send_map img.popclose').hover( function(){ // Change the input image's source when we "roll on" $(this).attr({ src : '/en/Images/btn_close2_over_tcm1006-274796.gif'}); }, function(){ // Change the input image's source back to the default on "roll off" $(this).attr({ src : '/en/Images/Btn_Close_tcm1006-273671.gif'}); } ); //Clinic locator submit button $('form#locator #submit_container input#locatorsubmit').hover( function(){ // Change the input image's source when we "roll on" $(this).attr({ src : '/en/Images/btn_go_over_tcm1006-274797.gif'}); }, function(){ // Change the input image's source back to the default on "roll off" $(this).attr({ src : '/en/Images/btn_go_tcm1006-271623.gif'}); } ); //email notification submit button $('#request_notification img.unsubscribehome').hover( function(){ // Change the input image's source when we "roll on" $(this).attr({ src : '/en/Images/btn_home_over_tcm1006-274822.gif'}); }, function(){ // Change the input image's source back to the default on "roll off" $(this).attr({ src : '/en/Images/btn_home_tcm1006-273118.gif'}); } ); //email signup submit button $('#request_notification_conf img.unsubscribehome').hover( function(){ // Change the input image's source when we "roll on" $(this).attr({ src : '/en/Images/btn_home_over_tcm1006-274822.gif'}); }, function(){ // Change the input image's source back to the default on "roll off" $(this).attr({ src : '/en/Images/btn_home_tcm1006-273118.gif'}); } ); //compare print button $('img.compareprint, .popup img.printicon').hover( function(){ // Change the input image's source when we "roll on" $(this).attr({ src : '/en/Images/btn_print_over_tcm1006-274824.gif'}); }, function(){ // Change the input image's source back to the default on "roll off" $(this).attr({ src : '/en/Images/btn_print_tcm1006-271401.gif'}); } ); //email signup submit button $('#request_notification .signupsubmit input.button, #request_notification .unsubscribesubmit input.button').hover( function(){ // Change the input image's source when we "roll on" $(this).attr({ src : '/en/Images/btn_submit_over_tcm1006-274826.gif'}); }, function(){ // Change the input image's source back to the default on "roll off" $(this).attr({ src : '/en/Images/btn_submit_tcm1006-271627.gif'}); } ); //send map submit button $('#sendPage input.printicon').hover( function(){ // Change the input image's source when we "roll on" $(this).attr({ src : '/en/Images/btn_send_over_tcm1006-274825.gif'}); }, function(){ // Change the input image's source back to the default on "roll off" $(this).attr({ src : '/en/Images/Btn_Send_tcm1006-273669.gif'}); } ); });