function update_lot(input) {
	// based on checked state of clicked lot's checkbox on page,
	// reloads page, setting the query string for the lot's update

	// gets lot number and checked state from form
	LotID = input.name;
	if(input.checked) {
		availability = 'sold';
	} else {
		availability = 'available';
	}

	// redirects browser to the same page, with query string
	window.location.href = 'index.php?LotID='+LotID+'&Status='+availability;
}

function highlight_on(layer) {
	// called from AREA element of image map
	// displays highlight overlay (neighborhood or lot)
	if(document.images[layer].style.display = 'none') {
		document.images[layer].style.display = 'block';
	}
}

function highlight_off(layer) {
	// called from mousing out of an overlay
	// hides the overlay again (neighborhood or lot),
	// if the highlight is not for the currently-viewed lot in the info panel
	if((document.images[layer].style.display = 'block') && (lot_on != layer)) { //  && layer != lot_on && lot_on != layer
		document.images[layer].style.display = 'none';
	}
}

function active_lot(layer) {
	active = lot_on;
	lot_on = layer;
	if(active != 0) {
		highlight_off(active);
	}

	// lot_on = layer;
}
