/*
** for the specifics needs of 25++ website by TeKniVision
*/

// the id of the element with overflow: auto set, in this case the div
var targBox = "content_main";

function scrollDivToAnchor(a) {	
	if (navigator.userAgent.indexOf("Safari") > -1) {		
		alert("test=" + a);
		
		var b = document.getElementById('content_main');
		alert ("b="+b+" top="+b.offsetTop);
		
		var anc = document.getElementById('#objectifs');
		alert ("a="+anc);
		//alert(" 1="+anc.offsetTop);
		//alert(" 2="+anc.offsetParent.offsetTop);
		//alert("3="+anc.style.top);
		//alert("4="+anc.offsetHeight);
		//alert("5="+anc.top);
		
		//b.scrollTop = document.getElementByName(anchor).offsetTop - b.offsetTop;
		/*
		
		docY = b.offsetTop - a.offsetTop;
		alert ("docY="+docY);
		//b.scrollTop =  docY + "px";*/
	}
	// alternately, if your elements are not nested within other nodes inside the box,
	// you could use document.getElementById(a).parentNode.scrollTop
	// that way you wouldn't need to specify the id of the scrollable box

}