function show_image(name) {
	var image_src = '../../../img/uploaded/big/' + name;
	var image_create = new Image();
	image_create.src = image_src;
	var html = '<img src="' + image_create.src + '" alt="" />';
	document.getElementById('big_image').innerHTML = html;
	}
function popup(id, image) {
	window.open('../popup/index/'+id+'/'+image,'popup','width=750,height=550,toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=yes,copyhistory=no,resizable=no')
	}
function printPage(id) {
	window.open('../popup/printpage/'+id,'popup','width=770,height=550,toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=yes,copyhistory=no,resizable=no')
	}
 function checkRadioValue() {
	var buttons = document.forms[1].elements['data[]'];
	for (var i = 0, len = buttons.length; i < len; i++) {
 	if(buttons[i].checked === true) {
	return true;
	}
	}
}

document.observe("dom:loaded", function() {
	$$(".home_tab_inactive").invoke("observe", "click", function() {showTabs(this) });
});

function showTabs(element) {
	var inactive = element.id;
	var active = inactive.replace('_inactive', '_active');
	var active_tab_content = active + '_content';
	$$(".home_tab_active").invoke('hide');
	$$(".home_tab_inactive").invoke('show');
	$(inactive).hide();	
	$(active).show();
	$$(".home_tab_content").invoke('hide');
	$(active_tab_content).show();
	}

function showSearchOptions(value) {
	$$(".extended_options").invoke('hide');
	if(value == 1 || value == 2 || value == 6 || value == 7) {
    element = 'options_' + value;
    document.getElementById(element).style.display = 'block';
	}
}
