window.onload=autoPOP;

/*
	function autoPOP()
	{
		var x = document.getElementsByTagName('a');
		for (var i=0;i<x.length;i++)
		{
			if (x[i].getAttribute('className') == 'popup' || x[i].getAttribute('class') == 'popup')
			{
				x[i].onclick = function () {
				return winOpen(this.href)
				}
			}
		}
	};

	function winOpen(url) {
		window.open(
			url,
			'popup',
			'width=560,height=700,scrollbars=1'
		);

		return false;
	};
*/

function autoPOP()
{
	var x = document.getElementsByTagName('a');
	for (var i=0;i<x.length;i++)
	{
		if (x[i].getAttribute('className') == 'popup02' || x[i].getAttribute('class') == 'popup02')
		{
			x[i].onclick = function () {
				return winOpen(this.href)
			}
		}
		else if (x[i].getAttribute('className') == 'popup03' || x[i].getAttribute('class') == 'popup03')
		{
			x[i].onclick = function () {
				return winOpen2(this.href)
			}
		}
	}
};

function winOpen(url) {
	window.open(
		url,
		'popup02',
		'width=500,height=700,scrollbars=1'
	);

	return false;
};

function winOpen2(url) {
	window.open(
		url,
		'popup03',
		'width=330,height=350,scrollbars=1'
	);

	return false;
};


