document.write('<script src="/_js/jquery-1.4.2.min.js" type="text/javascript"></script>');
document.write('<script src="/_js/jquery.tools.min.js" type="text/javascript"></script>');
document.write('<script src="/_js/jquery.dimensions.js" type="text/javascript"></script>');
document.write('<script src="/_js/jquery.positionBy.js" type="text/javascript"></script>');
document.write('<script src="/_js/jquery.bgiframe.js" type="text/javascript"></script>');
document.write('<script src="/_js/jquery.jdMenu.js" type="text/javascript"></script>');
document.write('<script src="/_js/cufon-yui.js" type="text/javascript"></script>');
document.write('<script src="/_js/jquery.tabs.min.js" type="text/javascript"></script>');
document.write('<script src="/_js/Waukegan_LDO_Extended_400-Waukegan_LDO_Extended_700.font.js" type="text/javascript"></script>');
//document.write('<script src="/_js/Waukegan_LDO_Extended_400-Waukegan_LDO_Extended_700-Waukegan_LDO_Extended_oblique_400-Waukegan_LDO_Extended_oblique_700.font.js" type="text/javascript"></script>');
//document.write('<script src="/_js/Waukegan_LDO_Extended_700-Waukegan_LDO_Extended_oblique_700.font.js" type="text/javascript"></script>');
document.write('<script src="/_js/swfobject.js" type="text/javascript"></script>');
document.write('<script src="/_js/jquery.colorbox-min.js" type="text/javascript"></script>');
document.write('<script src="/_js/jquery.livequery.js" type="text/javascript"></script>');



//--------------------
// Opens centered window
//--------------------
function centeredWindow(mypage, myname, w, h, scroll) {
var winl = (screen.width - w) / 2;
var wint = (screen.height - h) / 2;
winprops = 'height='+h+',width='+w+',top='+wint+',left='+winl+',scrollbars=yes,resizable=no,location=no,status=no'
win = window.open(mypage, myname, winprops)
}

// new window
function displayWindow(url, width, height) {
        var Win = window.open(url,"displayWindow",'width=' + width + ',height=' + height + ',resizable=0,scrollbars=yes,menubar=yes,address=yes,status=yes' );
}

// email page
function mailpage()
{
  mail_str = "mailto:?subject=WebMD Health Services: " + document.title;
  mail_str += "&body=Health Services you can count on. " + document.title;
  mail_str += ". You should check this out at, " + location.href; 
  location.href = mail_str;
}
// <a href="javascript:mailpage()">Email Page</a>


function getEmailAddress()
{
   if (document.getElementById("txtSubscribeEmail") != null && document.getElementById("txtSubscribeEmail").value != "Email Address")
   {
      return document.getElementById("txtSubscribeEmail").value;
   }
   return "";
}

function isSubscribeEnter(inField, e) {
    var charCode;
    
    if(e && e.which){
        charCode = e.which;
    }else if(window.event){
        e = window.event;
        charCode = e.keyCode;
    }

    if(charCode == 13) {
        //document.forms[0].action='/contact-us/'; 
        //document.forms[0].submit();
        document.location="/contact-us/?email=" + getEmailAddress();             
       return false;
    } 
    return true;
}

/* omniture functions */
    function linkTourSolutions() {
        var s = s_gi(s_account);
        s.linkTrackVars = 'prop4,eVar4,events';
        s.linkTrackEvents = 'event3';
        s.events = 'event3';
        s.eVar4 = 'Take a Tour Clicked:'+pageName;
        s.prop4 = 'Take a Tour Clicked:'+pageName;
        s.tl(this, 'o', 'Take a Tour Clicked');
        return true;
    }
    
    function linkPrintPage() {
        var s = s_gi(s_account);
        s.linkTrackVars = 'prop5,eVar5,events';
        s.linkTrackEvents = 'event4';
        s.events = 'event4';
        s.eVar5 = 'Print Page:'+pageName;
        s.prop5 = 'Print Page:'+pageName;
        s.tl(this, 'o', 'Print Page');
        return true;
    }
    
    function linkEmailPage() {
        var s = s_gi(s_account);
        s.linkTrackVars = 'prop6,eVar6,events';
        s.linkTrackEvents = 'event6';
        s.events = 'event6';
        s.eVar6 = 'Email Page:'+pageName;
        s.prop6 = 'Email Page:'+pageName;
        s.tl(this, 'o', 'Email Page');
        return true;
    }
    
    function linkVideo(videoName) {
        var s = s_gi(s_account);
        s.linkTrackVars = 'prop31,eVar31,events';
        s.linkTrackEvents = 'event31';
        s.events = 'event31';
        s.eVar31 = 'Testimonial Video:'+videoName;
        s.prop31 = 'Testimonial Video:'+videoName;
        s.tl(this, 'o', 'Testimonial Video');
        return true;
    }
    
    
    
    $(document).ready(function(){
        $('a[href*=www.webmd.com/careers]') 
            .livequery('click', function(event) { 
                var s=s_gi(s_account);
                s.linkTrackVars='prop21,eVar21,events';
                s.linkTrackEvents='event21';
                s.prop21 = 'Career Seeker';
                s.eVar21 = 'Career Seeker';
                s.events='event21';
                s.tl(this,'o',this.text);
                return true; 
            });         
    }); 
    
    // note that there isn't an exit link for resellers at this time
    $(document).ready(function(){
        $('a[href*=businessdevelopment]') 
            .livequery('click', function(event) { 
                var s=s_gi(s_account);
                s.linkTrackVars='prop22,eVar22,events';
                s.linkTrackEvents='event22';
                s.prop22 = 'Seeking Reseller';
                s.eVar22 = 'Seeking Reseller';
                s.events='event22';
                s.tl(this,'o',this.text);
                return true; 
            });         
    }); 
