function renderPlusone() {
	gapi.plusone.render("plusone-div",{"size":"small","annotation":"none"});
}

function set_onload(path, SubmodelID, Year){
	if (!SubmodelID) SubmodelID=0;
	if (!Year) Year=0;
	var top_strip = 	
		"<table width=\"770\" border=\"0\" align=\"center\" cellpadding=\"0\" cellspacing=\"0\">" +
			"<tr>" +
				
				"<td height=\"20\" width=\"150\">&nbsp;</td>" +  
			
				"<td height='20' align='right' valign='bottom' style='padding=bottom:4px;padding-right:5px' >" +
					"<div style='margin-bottom:2px;'><div id='plusone-div'></div></div></td>" +
				   
                   "<td width='15' height='15' align='right' valign='bottom' style='padding-right:2px;padding-bottom:2px'>" +
					"<a href='http://twitter.com/share?original_referer=pricelist.yad2.co.il&url=http://pricelist.yad2.co.il' class='bar'><IMG SRC='http://images.yad2.co.il/Pic/yad2new/page/icon_twitter_bird.jpg' WIDTH='15' HEIGHT='15' BORDER='0' ALT=''></a></td>" +         
				
                   
                   "<td width='15' height='15' align='right' valign='bottom' style='padding-right:2px;padding-bottom:2px'>" +
					"<a href='http://www.facebook.com/group.php?gid=322687392768' class='bar'><IMG SRC='"+ path +"images/headerlinks/ficon.jpg' WIDTH='15' HEIGHT='15' BORDER='0' ALT=''></a></td>" +         
				
                                       
				"<td width='34' height='20' align='right' valign='bottom'>" +
					"<a onclick=\"stat( '', 1662, '', '' );\" href='http://www.yad2.co.il' class='bar'><IMG SRC='"+ path +"images/headerlinks/yad2_logo_s.jpg' WIDTH='34' HEIGHT='19' BORDER='0' ALT='לוח יד2'></a></td>" +
				"<td height='20' align='right' valign='bottom' style='padding=bottom:4px;'>" +
					"<a href='javascript:void(0)' onClick=\"stat( '', 1662, '', '' );openWindow('"+ path +"adver.php', 'adver', 590, 660)\" class='bar'>פרסם באתר</a></td>" +
				"<td valign='bottom'>" +
					"<img src='http://images.yad2.co.il/Pic/site_images/pricelist/images/headerlinks/home4_03.gif' width='13' height='20' alt=''></td>" +
				"<td width='58' height='20' align='right' valign='bottom' style='padding=bottom:4px;'>" +
					"<a href='javascript:void(0)' onClick=\"openWindow('"+ path +"Contact.php', 'Contact', 590, 540)\" class='bar'>צור קשר</a></td>" +
				"<td valign='bottom'>" +
					"<img src='http://images.yad2.co.il/Pic/site_images/pricelist/images/headerlinks/home4_05.gif' width='15' height='20' alt=''></td>" +
				"<td width='73' height='20' align='right' valign='bottom' style='padding=bottom:4px;'>" +
					"<a href='javascript:void(0);'  onClick=\"openWindow('"+ path +"TellAFriend.php?SubModelID="+SubmodelID+"&Year="+Year+"', 'TellAFriend', 590, 540)\" class='bar'>המלץ לחבר</a></td>" +
				"<td valign='bottom'>" +
					"<img src='http://images.yad2.co.il/Pic/site_images/pricelist/images/headerlinks/home4_07.gif' width='20' height='20' alt=''></td>" +
				"<td width='81' height='20' align='right' valign='bottom' style='padding=bottom:4px;'>" +
					"<a href='javascript:if(document.all) window.external.AddFavorite(\"http://pricelist.yad2.co.il\",\"מחירון הרכב החדש של ישראל – לוח יד2\")' onMouseOver='return window.status=\"הוסף למועדפים\"' class='bar'>הוסף למועדפים</a></td>" +
				"<td valign='bottom'>" +
					"<img src='http://images.yad2.co.il/Pic/site_images/pricelist/images/headerlinks/home4_09.jpg' width='14' height='20' alt=''></td>" +
				"<td width='85' height='20' align='right' valign='bottom' style='padding=bottom:4px;'>" +
					"<a href='javascript:void(0)' onClick=\"this.style.behavior='url(#default#homepage)';this.setHomePage('http://pricelist.yad2.co.il/');\" onMouseOver=\"return window.status='הפוך לדף הבית'\" onMouseOut='return window.status=\"\"' class='bar'>הפוך לדף הבית</a></td>" +
				"<td valign='bottom'>" +
					"<img src='http://images.yad2.co.il/Pic/site_images/pricelist/images/headerlinks/home4_11.gif' width='16' height='20' alt=''></td>" +
				"<td>" +
					"<img src='http://images.yad2.co.il/Pic/site_images/pricelist/images/headerlinks/home4_12.gif' width='6' height='20' alt=''></td>" +
			"</tr>" +
		"</table>";
	var strip_div = document.getElementById("top_strip");
	strip_div.innerHTML = top_strip;
	
	renderPlusone();
	
}
function sortData(strURL, strSort)
{	
	var obj = window.event.srcElement;
	//alert(obj.tagName);
	if (obj.tagName == "TD")
	{		
		var ID = obj.id;
		if (ID)
		{			
			strURL += "&Sort=" + ID;
			if (strSort == ID)
			{
				strURL += "&DESC=DESC "
			}
			window.location.replace(strURL);
		}
	}
}
	
