sfHover = function() {
	var sfEls = document.getElementById("nav").getElementsByTagName("LI");
	for (var i=0; i<sfEls.length; i++) {
		sfEls[i].onmouseover=function() {
			this.className+=" sfhover";
		}
		sfEls[i].onmouseout=function() {
			this.className=this.className.replace(new RegExp(" sfhover\\b"), "");
		}
	}
}
if (window.attachEvent) window.attachEvent("onload", sfHover);


function charities() {
var location="http://www.unheritageapartager.ca/program/help/charities/";
var city = document.getElementById('CITY').value;
if (city) location = location + "city/" + city + "/";
var locIndex = document.getElementById('PROVINCE').selectedIndex;
var catIndex = document.getElementById('CATEGORY').selectedIndex;
if (locIndex != "0" || catIndex != "0")   location += "category/";

if (locIndex != "0")    location += document.getElementById('PROVINCE')[locIndex].value;

if (catIndex != "0") {
  if (locIndex != "0") location += "&";
  location += document.getElementById('CATEGORY')[catIndex].value;
}

if (locIndex != "0" || catIndex != "0")   location += "/";

window.location = location;
}

function charitiesN() {
var location="http://www.unheritageapartager.ca/program/help/charities/";
var name = document.getElementById('CHARITY').value;
if (name) location = location + "org/" + name + "/";
window.location = location;
}