/**
* MOD: Sig2Bottom
* Sets a bottom margin to div "postbody", based on the height of the signature.
*/

/*global onload, document */
sig2bottom = function()
{
	var a = document.getElementsByTagName('div');
	for (var i=0; i<a.length; i++)
	{
		if(a[i].getAttribute('id') == 'sigwrap')
		{
			var b = a[i].getElementsByTagName('div');
			for (var z=0; z<b.length; z++)
			{
				var id = b[z].getAttributeNode('id');
				var set = id.value;
				var sig = b[z].offsetHeight;z++;
				var cont = document.getElementById('c-'+set);z++;
				cont.style.marginBottom = ( sig + 10 ) + 'px';z++;
			}
		}
	}
};
sig2bottom();

// Loader for Prosilver
onload_functions.push('sig2bottom();');
