function fav() {
	var newT = document.createTextNode('Add To Favorites');
	var s = document.getElementById('fav');
	if (window.sidebar) {
		s.appendChild(newT);
		//s.style.color = '#00f';
		s.style.fontSize = '0.92em';
		s.style.fontWeight = 'bold';
		s.style.color = 'white';
		s.style.textAlign = 'center';
		s.style.cursor = 'pointer';
		s.style.borderRight = 'none';
		s.onclick = function() {window.sidebar.addPanel(document.title,self.location,'')};
		s.onmouseover = function() { s.style.backgroundColor='#B3CBE6'; s.style.color='black';}
		s.onmouseout = function() {s.style.backgroundColor='transparent'; s.style.color = 'white';}
	} else if (window.external) {
		s.appendChild(newT);
		//s.style.color = '#00f';
		s.style.fontSize = '0.92em';
		s.style.fontWeight = 'bold';
		s.style.color = 'white';
		s.style.textAlign = 'center';
		s.style.cursor = 'pointer';
		s.style.borderRight = 'none';
		s.onclick = function() {window.external.AddFavorite(self.location,document.title)};
		s.onmouseover = function() { s.style.backgroundColor='#B3CBE6'; s.style.color='black';}
		s.onmouseout = function() {s.style.backgroundColor='transparent'; s.style.color = 'white';}
	} else if (window.opera) {
		s.appendChild(newT);
		//s.style.color = '#00f';
		s.style.fontSize = '0.92em';
		s.style.fontWeight = 'bold';
		s.style.color = 'white';
		s.style.textAlign = 'center';
		s.style.cursor = 'pointer';
		s.style.borderRight = 'none';
		s.onclick = function() {
					     var e = document.createElement('a');
					     e.setAttribute('href',self.location);
					     e.setAttribute('title',document.title);
					     e.setAttribute('rel','sidebar');
					     e.click();
	  				}
	  	s.onmouseover = function() { s.style.backgroundColor='#B3CBE6'; s.style.color='black';}
		s.onmouseout = function() {s.style.backgroundColor='transparent'; s.style.color = 'white';}
	}
}

var pageLoaded = 0;
window.onload = function() {pageLoaded = 1;}
function loaded(i,f) {
	if (document.getElementById && document.getElementById(i) != null) f();
	else if (!pageLoaded) setTimeout('loaded(\''+i+'\','+f+')',100);
}
loaded('fav',fav);