
function showDialog(type, id)
{
	var x = 100;
	var y = 100;
	
	var w, h;
	
	if (type == 'edit' || type == 'show')
	{
		w = 500;
		h = 400;
	}
	else
	{
		w = 300;
		h = 100;
	}
	
	if (window.screen)
	{
		x = (screen.width - w) / 2;
		y = (screen.height - h) / 2 - 100;
	}
	
	url = '/forum/moderate/' + type + '/' + id;
	
	window.open(url, '', 'width=' + w + ',height=' + h + ',top=' + y + ',left=' + x);
}