// change image
function img_suffix(name, suffix) {
	if (document.images) {
		var basename = document.images[name].src
		var pos1 = basename.lastIndexOf('/')
		var pos2 = basename.lastIndexOf('_')
		var pos3 = basename.lastIndexOf('.gif')
		basename = basename.substring(0, pos2>pos1 && pos3>pos2 ? pos2 : pos3)
		document.images[name].src = basename + suffix + '.gif'
	}
}

// link animation
function img_over(name, msg) {
	img_suffix(name, '_over')
	window.status = msg
	return true
}
function img_out(name) {
	img_suffix(name, '')
	window.status = ''
}
function img_down(name) {
	img_suffix(name, '_down')
}
function img_preload(name) {
	if (document.images) {
		var image = new Image
		image.src = name
	}
}

