var IE = document.all?true:false;
if (!IE) document.captureEvents(Event.MOUSEMOVE)
document.onmousemove = getPosition;
var X = 0
var Y = 0

if (!document.all)
document.captureEvents(Event.MOUSEMOVE)

// On the move of the mouse, it will call the function getPosition
document.onmousemove = getPosition;

// These varibles will be used to store the position of the mouse
var X = 0
var Y = 0

// This is the function that will set the position in the above varibles 
function getPosition(args) 
{
  // Gets IE browser position
  if (IE) 
  {
    X = event.clientX + document.body.scrollLeft;
    Y = event.clientY + document.body.scrollTop;
  }
  
  // Gets position for other browsers
  else 
  {  
    X = args.pageX
    Y = args.pageY
  }  
}

function popUp(partner)
{
    var div;
    
    var partners = new Array();
    partners.push(["coned","Con Edison has a long-established tradition of contributing to and maintaining the social, cultural, and economic vitality of our service areas throughout New York City and Westchester County. We are widely recognized for our contributions to energy efficiency and environmental responsibility.<br /><br />Visit <a target=\"_blank\" href=\"http://conEd.com/thepowerofgreen\">conEd.com/thepowerofgreen</a> to find out how ways you can use less energy, help save the environment and, save you some green. You'll find energy-saving tips galore, a fun Power of Green game, and links to many other resources. After you have explored the Power of Green site, join us on <a target=\"_blank\" href=\"http://facebook.com/powerofgreen\">Facebook</a>.<br /><br />And for those who are really connected, go to our Web site to download our new and free Power of Green App. It features illustrated energy-saving tips and a collection of video tips to view on your iPhone or iPod.<br /><br />Con Edison, one of the nation's largest investor-owned energy companies, provides electric, gas, and steam service to more than nine million people in New York City and Westchester County, New York."]);
   partners.push(["aquafina","<strong>Aquafina&reg;</strong><br /><br />Aquafina loves water and is first and foremost committed to providing the best there can be. Our advanced filtration process consistently delivers the clearest, cleanest and most consistently pure tasting water. And we don't stop there! We are also committed to reducing our impact on the environment. Aquafina bottles are 100% recyclable, but that's just the beginning. Thanks to innovations and investments in our packaging, we've reduced the amount of packaging in our leading Aquafina bottle, the half-liter bottle, every year since 2002. In 2009, we introduced our lightest package ever, the new Eco-Fina Bottle&trade; with 50% less plastic than 2002.<br /><br />In addition, we are supporting recycling and eco-volunteerism initiatives nationwide through our community partnership program. Every one of us is a part of something bigger, and we can be better working and acting together.<br /><br />To learn more, visit us at <a target=\"_blank\" href=\"http://aquafina.com\">aquafina.com</a>."]);
   partners.push(["benmoore","Benjamin Moore Paints, founded in 1883 in Brooklyn, New York, is renowned for its high performance paints, extraordinary colors, and its unrelenting role in preserving, protecting and beautifying building interiors and exteriors throughout North America. Consistently, it is the brand of choice for professional contractors and interior designers, alike.<br /><br />The company embraces today's global challenge to help restore and ensure the health of planet Earth, and with that goal in mind developed the Benjamin Moore Green Promise&trade;, a designation assuring that its portfolio of meticulously crafted, environmentally sensitive products meet and exceed the strictest industry standards while also upholding premium levels of performance. Natura&reg; Interior Waterborne Paint is among the array of products that delivers on that Green Promise. It is the greenest, lowest emission paint available at zero VOCs in any color and virtually no odor.<br /><br />Benjamin Moore's integrity and commitment to the environment extend well beyond the products it manufactures. The company has a proud and longstanding history of supporting many worthy initiatives, including the work of the Wildlife Conservation Society and the Bronx Zoo.<br /><br />For more about Natura from Benjamin Moore, visit <a target=\"_blank\" href=\"http://benjaminmoore.com/natura\">benjaminmoore.com/natura</a>."]);
   partners.push(["monroe","<strong>Monroe College</strong><br /><br />Since its founding in 1933, Monroe College has provided professional, career-oriented higher education to students from diverse backgrounds who enrich their lives in a personalized, supportive environment.  Monroe faculty are passionate about teaching and are selected for their experience as practitioners in their chosen field.<br /><br />More than 7,000 students are enrolled at Monroe's New Rochelle and Bronx campuses where they earn Associate, Bachelor's, and Masters degrees in business and accounting, criminal justice, health professions, hospitality and culinary, and information technology.<br /><br />As part of its commitment, Monroe is an enthusiastic community partner supporting development and environmental initiatives.  This has included planting trees, initiating parks and empty-lot cleanups, and basic sanitation and maintenance of neighboring streets.<br /><br />With its Green Apple City project, the college's award-winning SIFE team is educating Bronx residents about how saving energy can also save money.<br /><br />In Ustin Hall, a building opened on Jerome Avenue in 2008, the college installed solar technology on its rooftop that provides an estimated 57,000 KW hours of electricity and insulation materials that reduces the building's heating and cooling needs.<br /><br />Monroe College is a proud sponsor of Run for the Wild and avid supporter of the Bronx Zoo and Wildlife Conservation Society."]);
   partners.push(["montefiore","<a target=\"_blank\" href=\"http://www.montefiore.org/\">Montefiore Medical Center</a> encompasses 126 years of outstanding patient care, innovative medical &ldquo;firsts,&rdquo; pioneering clinical research, dedicated community service and ground-breaking social activism. A full-service, integrated delivery system caring for patients in the New York metropolitan region and beyond, Montefiore is a 1,491-bed medical center that includes: four hospitals -- the Henry and Lucy Moses Division, the Jack D. Weiler Division, the North Division and The Children&rsquo;s Hospital at Montefiore; a large home healthcare agency; <a target=\"_blank\" href=\"http://www.montekids.org/programs/school/\">the largest school health program</a> in the US; a 22-site <a target=\"_blank\" href=\"http://www.montefiore.org/services/mmg/\">medical group</a> practice integrated throughout the Bronx and Westchester; and, a care management organization providing services to 179,000 health plan members.<br><br>In 2008 and 2009, The <a target=\"_blank\" href=\"http://www.montekids.org/\">Children&rsquo;s Hospital at Montefiore</a> was ranked as one of &ldquo;America&rsquo;s Best Children&rsquo;s Hospitals&rdquo; in US News &amp; World Report&rsquo;s prestigious annual listing. The Leapfrog Group lists Montefiore among the top one percent of all U.S. hospitals based on its strategic investments in sophisticated and integrated healthcare technology.<br><br>Montefiore is committed to meeting the healthcare needs of the future through medical education and manages one of the largest residency programs in the country. Montefiore is The University Hospital and Academic Medical Center for <a target=\"_blank\" href=\"http://www.aecom.yu.edu/home/default.asp\">Albert Einstein College of Medicine</a> and has an affiliation with <a target=\"_blank\" href=\"http://www.nymc.edu/\">New York Medical College</a> for residency programs at the North Division.<br><br> Distinguished centers of excellence at Montefiore include <a target=\"_blank\" href=\"http://www.montefiore.org/services/coe/heart/\">cardiology and cardiac surgery</a>, <a target=\"_blank\" href=\"http://www.montefiore.org/services/coe/cancer/\">cancer care</a>, tissue and organ transplantation, <a target=\"_blank\" href=\"http://www.montefiore.org/services/coe/pediatrics/\">children&rsquo;s health</a>, <a target=\"_blank\" href=\"http://www.montefiore.org/services/coe/womenshealth/\">women&rsquo;s health</a>, <a target=\"_blank\" href=\"http://www.montefiore.org/services/coe/surgery/\">surgery and the surgical subspecialties</a>. Montefiore is a national leader in the research and treatment of diabetes, <a target=\"_blank\" href=\"http://www.montefiore.org/services/headache_center/\">headaches</a>, obesity, <a target=\"_blank\" href=\"http://www.montefiore.org/services/sleepdisorders/\">cough and sleep disorders</a>, <a target=\"_blank\" href=\"http://www.montefiore.org/services/geriatrics/\">geriatrics and geriatric psychiatry</a>, <a target=\"_blank\" href=\"http://www.montefiore.org/services/neurology/\">neurology</a> and <a target=\"_blank\" href=\"http://www.montefiore.org/services/coe/surgery/neurological/\">neurosurgery</a>, adolescent and <a target=\"_blank\" href=\"http://www.montefiore.org/prof/departments/family/\">family medicine</a>, HIV/AIDS and <a target=\"_blank\" href=\"http://www.montefiore.org/prof/departments/family/\">social</a> and environmental medicine, among many other specialties. For more information, please visit <a target=\"_blank\" href=\"http://www.montefiore.org\">www.montefiore.org</a> or <a target=\"_blank\" href=\"http://www.montekids.org\">www.montekids.org</a>."]);
   partners.push(["wabc","WABC-TV, Channel 7 is the ABC owned television station in New York City, serving more than 7.4 million television households in 29 counties covering New York, New Jersey, Connecticut and Pennsylvania. It is also the most watched local television station in the United States. For more than 60 years, ABC7 has consistently been the leader in local news and local and national entertainment programming.  Channel 7's mission is to provide viewers with the same commitment to excellence that has consistently kept us New York's #1 station, and the #1 station in the nation... quality news and programming, cutting edge technology and ongoing community outreach.<br /><a target=\"_blank\" href=\"http://www.7online.com\">www.7online.com</a>"]);
   partners.push(["stamford","Stamford Tent approaches every project with the utmost respect for our clients, guests and the particular goals of each event. Professionally developed Best Practices based upon 53 years of experience, ensures proper planning and logistics from conceptual stage to completion, offering peace of mind and customer satisfaction.  When professionalism, creativity and reliability are of utmost importance, Stamford Tent & Event Services delivers on expectations. <a target=\"_blank\" href=\"http://www.stamfordtent.com\">www.stamfordtent.com</a>"]);
   partners.push(["babylovesdisco","The popular toddler dance party, <a target=\"_blank\" href=\"http://www.babylovesdisco.com\">Baby Loves Disco</a>, is descending back on <a target=\"_blank\" href=\"http://lepoissonrouge.com/events/view/975\">(Le) Poisson Rouge</a>...and the diaper-clad booties will be shakin', yo! On Sunday March 21st from Noon to 3:00 the trendy West Village hot spot will be child proofed and Lysoled so that parents and their progeny (aged 7 and below) can boogie on down with their rad selves.<br /><br />Baby loves disco is an afternoon dance party featuring real music spun and mixed by real djs blending classic disco tunes From the 70s, & 80s guaranteed to get those little booties moving and grooving. The fun spills out from all corners of the club: bubble machines, baskets of scarves and egg-shakers, a chill-out room (with tents, books and puzzles), diaper changing stations, a full spread of healthy snacks and dancing, LOTS of dancing. But at it's core, Baby loves disco is a community event that brings kids together with kids and parents together with parents."]);
   partners.push(["liparentsource","LIParentSource.com is the most comprehensive online resource for families on Long Island.  Whatever you are looking for, from local businesses to events to discounts and coupons, you will find on LIParentSource.com.  Don't miss out!  Visit us today and register for our free weekly e-newsletter - <a target=\"_blank\" href=\"http://www.LIParentSource.com\">www.LIParentSource.com</a>"]);
   partners.push(["metropolitanmoms","<strong>Metropolitan Moms</strong><br /><a target=\"_blank\" href=\"http://www.metropolitanmoms.com\">www.metropolitanmoms.com</a><br /><br />Metropolitan Moms and the Bronx Zoo have a slew of family friendly seasonal festivities especially for kids. Be sure mention the Bronx Zoo when you register for any winter/spring Metropolitan Moms class to receive a 15% discount."]);
   partners.push(["momslikeme","Created for moms and by moms, New York City <a target=\"_blank\" href=\"http://MomsLikeMe.com\">MomsLikeMe.com</a> is where moms who live near you hang out - and let it all out. New moms. Working moms. Stay-at-home moms. Where you can share stories, swap advice, make friends and even make plans to meet up live. Join the conversation today."]);
   partners.push(["myconnecticutkids","MyConnecticutKids.com provides parents an opportunity to find fun that the whole family can participate in, in and around Connecticut.<br /><br />Destinations, Events, Activities and classes can all be found on <a target=\"_blank\" href=\"http://MyConnecticutKids.com\">MyConnecticutKids.com</a></a> today!!"]);
   partners.push(["nysc","<strong>New York Sports Clubs</strong><br /><br />A membership gets you more than admission to our clubs. You also get a Smarter Fitness experience &mdash; proactive fitness pros providing engaging and effective programs and services in a friendly, supportive environment.<br /><br />Featuring:<br /><br /><strong>&bull; </strong>Cardio equipment that monitors and entertains.<br /><br /><strong>&bull; </strong>A wide variety of free group exercise classes like Spin&reg;, yoga, and Pilates.<br /><br /><strong>&bull; </strong>XpressLine 22-minute total-body workout.<br /><br /><strong>&bull; </strong>Kids Playroom with baby-sitting.<br /><br /><strong>&bull; </strong>Sports Clubs for Kids Programs at select clubs.<br /><br />Visit <a target=\"_blank\" href=\"http://MySportsClubs.com\">MySportsClubs.com</a> for locations."]);
    
    if(document.getElementById)
    // Standard way to get element
    div = document.getElementById('popupWindow'); 
    else if(document.all) 
    // Get the element in old IE's 
    div = document.all['popupWindow']; 
    
    
	for(var x = 0; x < partners.length; x++) {
    	if (partners[x][0] == partner) {
    		div.innerHTML = partners[x][1]+"<br /><br /><a href=\"javascript:popUp('');\">Close</a>";	
    	}
    }

    // if the style.display value is blank we try to check it out here 
    if(div.style.display==''&&div.offsetWidth!=undefined&&div.offsetHeight!=undefined)
    {
        div.style.display = (div.offsetWidth!=0&&elem.offsetHeight!=0)?'block':'none'; 
    }
    
    // If the PopUp is hidden ('none') then it will display it ('block').
    // If the PopUp is displayed ('block') then it will hide it ('none').
    div.style.display = (div.style.display==''||div.style.display=='block')?'none':'block';
    
    // Off-sets the X position by 15px
    X = X + 15;
        
    // Sets the position of the DIV
    div.style.left = X+'px';
    div.style.top = Y+'px';
    
    if (IE) {
    	div.style.top = event.clientY + document.body.scrollTop + 'px';
    	}
    
}

function toggleField (fld,str) {
	fldValue = document.getElementById(fld).value;
	
	if (fldValue == str) {
		document.getElementById(fld).value = "";
		document.getElementById(fld).style.color = "#000000";
		
		if (str == "Password") {
			document.getElementById(fld).type = "password";
			}
		
		}
	else {	
		if (fldValue == "") {
			document.getElementById(fld).value = str;
			document.getElementById(fld).style.color = "#a89c6f";
			
			if (str == "Password") {
				document.getElementById(fld).type = "text";
				}
			}
		}
	}
