
function boxresize()
{
	var myBoxes = $$('.productbox');
	var Arr = $A();
	var i = -1;
	myBoxes.each(function(myBox, counter)
	{
		if ((counter % 3) == 0)
		{
			maxHeight = 0;
			i++;
			Arr[i] = $A();
		}
		maxHeight = Math.max(myBox.getHeight(),maxHeight);
		Arr[i][counter % 3] = myBox;

		if ( (counter % 3) == 2 || counter == (myBoxes.length - 1) )
		{
			Arr[i].invoke('setStyle', { height: maxHeight + 'px' });
		}
	});
}
document.observe("dom:loaded", boxresize);
