function CambiaElenco(sCategoria, sElenco, sCampo) {
	$(sCampo).set('html', '<div style="text-align: center;"><img src="/imgs/loading.gif" style="width: 148px; height: 27px; hspace: 2px; border: 0px;" alt="Caricamento in corso..." title="Caricamento in corso..." /><\/div>');
	var req = new Request.HTML({
		url: '/annunci_func.asp',
		method: 'get',
		onSuccess: function(html){
			$(sCampo).set('text', '');
			$(sCampo).adopt(html);
		},
		// Our request will most likely succeed, but just in case, we'll add an
		// onFailure method which will let the user know what happened.
		onFailure: function(){
			$(sCampo).set('text', 'The request failed.' + "cat=" + sCategoria + "&elenco=" + sElenco);
		}
	}).send("cat=" + sCategoria + "&elenco=" + sElenco);
}

function CambiaElenco1(sCategoria, sElenco, sCampo) {
	$(sCampo).set('html', '<div style="text-align: center;"><img src="/imgs/loading.gif" style="width: 148px; height: 27px; hspace: 2px; border: 0px;" alt="Caricamento in corso..." title="Caricamento in corso..." /><\/div>');
	var req = new Request.HTML({
		url: '/annunci_func.asp',
		method: 'get',
		onSuccess: function(html){
			$(sCampo).set('text', '');
			$(sCampo).adopt(html);
			var links = $$("a").filter(function(el) {
				return el.rel && el.rel.test(/^lightbox/i);
			});
//			$$(links).slimbox({/* Put custom options here */}, null, function(el) {
//				return (this == el) || ((this.rel.length > 8) && (this.rel == el.rel));
//			});
			if (self.ReMooz !== undefined) {
				ReMooz.assign('.ZoomReMooz', {
					'origin': 'img',
					'shadow': 'onOpenEnd',
					'resizeFactor': 0.9,
					'cutOut': false,
					'opacityResize': 0.4,
			//		'dragging': false,
					'centered': true
				});
			};
		},
		// Our request will most likely succeed, but just in case, we'll add an
		// onFailure method which will let the user know what happened.
		onFailure: function(){
			$(sCampo).set('text', 'The request failed.' + "cat=" + sCategoria + "&elenco=" + sElenco);
		}
	}).send("cat=" + sCategoria + "&elenco=" + sElenco);
}

function CambiaGenere(sGenere, sCampo) {
	if (sGenere > 0) {
		$(sCampo).set('html', '<div style="text-align: center;"><img src="/imgs/loading.gif" style="width: 148px; height: 27px; hspace: 2px; border: 0px;" alt="Caricamento in corso..." title="Caricamento in corso..." /><\/div>');
		var req = new Request.HTML({
			url: '/annunci_func.asp',
			method: 'get',
			onSuccess: function(html){
				$(sCampo).set('text', '');
				$(sCampo).adopt(html);
			},
			// Our request will most likely succeed, but just in case, we'll add an
			// onFailure method which will let the user know what happened.
			onFailure: function(){
				$(sCampo).set('text', 'The request failed.' + "cat=" + sCategoria + "&elenco=" + sElenco);
			}
		}).send("cat=" + sGenere + "&elenco=genere");
	}
	else {
		$(sCampo).set('text', '');
	}
}
