function picInher(theImage) {
	attempt = getOneUp(theImage.src);
	if (attempt != ("http://")) {
		theImage.src = attempt;
	}
}

function picInher2(theImage, imageName, level) {
	var sub = theImage.src;
	for (var i = 0; i < level+1; i++) {   
		n = sub.lastIndexOf('/');
		sub = theImage.src.substring(0,n);
	}
	theImage.src = sub + '/' + imageName;
	// weggehaald ivm bug 6995, 6996, 6998, 6999, 7001
	//theImage.onerror = void(0);
}

function getOneUp(oldPath) {
	n = oldPath.lastIndexOf('/');
	fileName = oldPath.substring(n+1);
	dirName = oldPath.substring(0,n);
	m = dirName.lastIndexOf ('/');
	newPath = dirName.substring(0,m+1) + fileName;
	return newPath;
}

function refreshSize(obj) {
	obj.style.width = "auto";
}
