/*******************************************/
// Javascript for SteveKent.ca template
//
// Author:	Greg Browne
// Company:	Root Four Imagination Inc.
// Date:	Sep 2011
// Contact:	gbrowne@lemurmonitors.com
/*******************************************/

function writeHeader()
{
	document.write("<tr><td colspan='2' style='border: solid; border-color: #336699; border-width: 0px 0px 1px 0px; padding-top: 8px'>");
	document.write("<a href='index.html'><img src='images/SteveKentHeader.png' alt='On October 11th Re-elect Steve Kent - Mount Pearl North - PC' /></a></td></tr>");
}

function writeTopContent()
{
	document.write("<tr><td style='padding-top: 8px; text-align: left; padding-left: 8px'>");
	document.write("	<a href='about.html'><img src='images/About.png' alt='About' class='menuButtons' /></a><br />");
	document.write("	<a href='events.html'><img src='images/Events.png' alt='Events' class='menuButtons' /></a><br />");
	document.write("	<a href='media.html'><img src='images/Media.png' alt='Media' class='menuButtons' /></a></td>");
	document.write("<td style='text-align: right; padding-right: 12px'><img src='images/New-Energy-Banner.jpg' alt='New Energy' /></td></tr>");
}

function writeIcons()
{
	document.write("<tr><td colspan='2'>");
	document.write("	<a href='contact.html'><img src='images/buttonContact.png' alt='Contact Steve' class='icons' /></a>");
	document.write("	<a href='donate.html'><img src='images/buttonDonate.png' alt='Donate' class='icons' /></a>");
	document.write("	<a href='volunteer.html'><img src='images/buttonVolunteer.png' alt='Volunteer' class='icons' /></a>");
	document.write("	<a href='lawnsign.html'><img src='images/buttonLawnSign.png' alt='Get a Lawn Sign' class='icons' /></a>");
	document.write("	<a href='vote.html'><img src='images/buttonVote.png' alt='Vote' class='icons' /></a>");
	document.write("	<a href='spotsteve.html'><img src='images/buttonSpotSteve.png' alt='Spot Steve' class='icons' /></a>");
	document.write("	<a href='steveonthemove.html'><img src='images/buttonOnTheMove.png' alt='Step with Steve' class='icons' /></a>");
	document.write("	<a href='http://www.facebook.com/stevekentpc' target='_blank'><img src='images/buttonFacebook.png' alt='Follow Steve on Facebook' class='icons' /></a>");
	document.write("	<a href='http://twitter.com/stephenkent' target='_blank'><img src='images/buttonTwitter.png' alt='Follow Steve on Twitter' class='icons' /></a></td></tr>");
}

function writeFooter()
{
	document.write("<tr><td colspan='2' style='text-align: left; padding-left: 8px'>");
	document.write("	<img src='images/SteveKentFooter.png' alt='Footer' usemap='#footerMap' />");
	document.write("	<map name='footerMap' id='footerMap'>");
	document.write("		<area shape='rect' title='Mount Pearl North' alt='Mount Pearl North' coords='0,76, 262,0' href='mount-pearl-north.html' />");
	document.write("		<area shape='rect' title='Steve&#39;s Blog' alt='Steve&#39;s Blog' coords='262,76, 462,0' href='blog.html' />");
	document.write("		<area shape='rect' title='Join Steve&#39;s Newsletter' alt='Join Steve&#39;s Newsletter' coords='462,76, 712,0' href='newsletter.html' />");
	document.write("		<area shape='rect' title='2011 Dunderdale' alt='2011 Dunderdale' coords='712,76, 992,0' href='http://www.dunderdale2011.ca/' target='_blank' /></map>");
	document.write("<div style='padding-top: 4px; text-align: center; font-style: italic'>745-KENT (5368) | <a href='mailto:steve@stevekent.ca'>steve@stevekent.ca</a></div></td></tr>");
}

function writeSideShadow(side)
{
	document.write("<td width='24px' style='background-image: url(\"images/ShadowSlice" + side + ".png\"); background-repeat: repeat-y;'>&nbsp;</td>");
}

function writeBottomShadow()
{
	document.write("<tr><td><img src='images/leftCorner.png' /></td>");
	document.write("<td style='background-image: url(\"images/bottomShadowSlice.png\"); background-repeat: repeat-x;'>&nbsp;</td>");
	document.write("<td><img src='images/rightCorner.png' /></td></tr>");
}

function playYouTube(playerID, vidId, width, height)
{
	document.getElementById(playerID).innerHTML = "<iframe width='" + width + "' height='" + height + "' src='http://www.youtube.com/embed/" + vidId + "?autoplay=1' frameborder='0' allowfullscreen></iframe>";
}

