function move(elemName, amount)
{
	elem = document.getElementById(elemName);
	
	
	if(elem.style.marginLeft == '')
	{
		elem.style.marginLeft = '0px';
	}
	
	if((parseInt(elem.style.marginLeft) + amount) > (0 - getMaxSize()))
	{
		elem.style.marginLeft = (parseInt(elem.style.marginLeft) + amount) + 'px';
	}
	
	if(parseInt(elem.style.marginLeft) > 0)
	{
	
		elem.style.marginLeft = '0px';
	}
				
}

function getMaxSize()
{
	maxSize = 0;
	childs = document.getElementById('itemlistmini').childNodes
	for(i=0;i<childs.length;i++)
	{
		if(childs[i].className == 'produktwrap')
		{
			maxSize += 117;
		}
	}
	return maxSize;
}
