function popup(url, title, big) {
	var pd = new PopupDialog();
	pd.close();
	pd.open(url, title, big);
}

function popup_link_callback() {
	var $a = $(this);
	var url = $a.attr('href');
	var title = $a.attr('title');
	if(!title) title = '&nbsp;&nbsp';
	var big = /big/.test($a.attr('class'));
	popup(url, title, big);
	return false;
}

$(function() {
	$('a.popup').click(popup_link_callback);
});
