/* Image Load Function */
function LoadGIF(image) {
   var rollover = document.images;
   if (rollover) {
      eval (image + ' = new Image()');
      eval (image + '.src  = "/images/nav/' + image + '.gif"');
   }
}

LoadGIF('chamberinfo_on');
LoadGIF('communityinfo_on');
LoadGIF('eventcalendar_on');
LoadGIF('home_on');
LoadGIF('membershipdir_on');
LoadGIF('photogallery_on');
LoadGIF('realestate_on');
LoadGIF('relocationinfo_on');
LoadGIF('visitinghmb_on');
LoadGIF('wheredine_on');
LoadGIF('wherestay_on');
LoadGIF('coastal_ecotourism_on');


/* This creates the copywrite statment at bottom of page */

function include_copyright(startyear) {
   var   blob="";
   var msistartyear = 1996;
   var   today=new Date();
   var   thisyear = get_full_year(today);
   if (startyear < thisyear && startyear >= msistartyear) {
      blob += startyear + " - ";
   }
   blob += thisyear;
// blob = "<table width='468' border='0' cellspacing='0' cellpadding='0' id='footer'><tr><td width='496' class='body2'><img src='http://www.halfmoonbaychamber.org/images/powered_by_weblink.gif' width='145' height='28' alt='' border='0' align='right'>&copy; Copyright " + blob + " by Half Moon Bay Coastside Chamber of Commerce & Visitors’ Bureau.<br>\n All rights reserved.  Photo credits:  (Point Montara Lighthouse) VITO - Palmisano Photo Ltd.<br> Half Moon Bay Coastside Chamber of Commerce & Visitors’ Bureau &nbsp;<a href='/site_map.html' class='body2link'>[SITE MAP]</a><br>\n 235 Main Street Half Moon Bay, CA 94019<br>\n  Phone:&nbsp;(650) 726-8380&nbsp;&nbsp;Fax:&nbsp;(650) 726-8389&nbsp;&nbsp;Email:&nbsp; <a href='mailto:info@hmbchamber.com' class='body2link'>info@hmbchamber.com</a>\n</td>\n<td colspan='4'><img src='http://www.halfmoonbaychamber.org/images/spacer.gif' width='1' height='14' alt='' border='0'><br><a href='http://www.chamberweblink.com/' target='_blank'></a></td></tr></table>d></tr></table>";

blob = "<table width='468' border='0' cellspacing='0' cellpadding='0' id='footer'><tr><td height='4' bgcolor='#FBB600'><img src='http://www.halfmoonbaychamber.org/images/images/spacer.gif' height='4' width'468'></td></tr><tr><td height='10' ><img src='http://www.halfmoonbaychamber.org/images/spacer.gif' height='10' width'468'></td></tr><tr><td height='1' bgcolor='#595B72'><img src='http://www.halfmoonbaychamber.org/images/spacer.gif' height='1' width'468'></td></tr><tr><td height='21'><img src='http://www.halfmoonbaychamber.org/images/spacer.gif' height='21' width'468'></td></tr><tr><td width='496'><tr><td class='body1'>&copy; Copyright " + blob + " by Half Moon Bay Coastside Chamber of Commerce & Visitors’ Bureau. All rights reserved.  Photo credits:  (Point Montara Lighthouse) VITO - Palmisano Photo Ltd.<br><br>Half Moon Bay Coastside Chamber of Commerce & Visitors’ Bureau &nbsp;<a href='http://www.halfmoonbaychamber.org/site_map.html' class='body2link'>[SITE MAP]</a><br>\n 235 Main Street Half Moon Bay, CA 94019<br>\n  Phone:&nbsp;(650) 726-8380&nbsp;&nbsp;Fax:&nbsp;(650) 726-8389&nbsp;&nbsp;Email:&nbsp; <a href='mailto:info@hmbchamber.com' class='body2link'>info@hmbchamber.com</a>\n</td>\n</tr></table>";

   return blob;
}

/* 
** subroutine: get_full_year
** param1: d -> date.  any date object.
*/
function get_full_year(d) { // d is a date object
   yr = d.getYear();
   if (yr < 1000) {
      yr+=1900;
   }
   return yr;
}


/*
openChildWin()
For pricvacy policy child window */
function openChildWin(aURL) {
var openWin = window.open(aURL,"childwin","resizable=0,location=0,status=0,menubar=0,toolbar=0,scrollbars=1,width=400,height=300,left=0,top=0,screenX=0,screenY=0");
openWin.opener = window;
openWin.focus();
}

