function ShowLoader( id )
{
	element = $(id);
	element.setAttribute("class", "show");
	element.setAttribute("className", "show");
}

function HideLoader(id)
{
	element = $(id);
	element.setAttribute("class", "hide");
	element.setAttribute("className", "hide");
}

function func( id ) 
{
	// SET PATH to PHP FILE handling the REQUEST
	var url = '../include/ajax_portfolio_pieces.php';
	
	// SET PARAMETERS
	var pars = 'piece_id='+parseInt(id);

	// SET ID of the element were the responce goes
	var target = 'chart_info';

	// SHOW the loader
	ShowLoader('loading');

	// AJAX Updater by prototype
	var myAjax = new Ajax.Updater(target, url, {method: 'post', parameters: pars, onComplete: HideLoader('loading')});
	
	
	////////////////
	// Showing NEWS
	

	// SHOW the news panel
	ShowLoader('sub_news');
	
	// SET PATH to PHP FILE handling the REQUEST
	var url = '../include/ajax_portfolio_news.php';
	
	// SET ID of the element were the responce goes
	var target = 'our_news';
	
	// SHOW the loader
	ShowLoader('loading');
	
	// AJAX Updater by prototype
	var myAjax = new Ajax.Updater(target, url, {method: 'post', parameters: pars, onComplete: HideLoader('loading')});
	
	//$('our_accounts').remove();
	
	//return;
	///////////////////
	// Showing ACCOUNTS
	
	// SET PATH to PHP FILE handling the REQUEST
	var url = '../include/ajax_portfolio_accounts.php';
	
	// SET ID of the element were the responce goes
	var target = 'our_accounts';
	
	// SHOW the loader
	ShowLoader('loading');
	
	// AJAX Updater by prototype
	var myAjax = new Ajax.Updater(target, url, {method: 'post', parameters: pars, onComplete: HideLoader('loading')});

}


//added on 19.07.2006
function popUp_news(URL) {
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,width=700,height=700');");
}
function popUp_news2(URL) {
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,width=300,height=300');");
}