Ext.onReady(function(){
						
						// accesso utenti
						var win;
						var button = Ext.get('accesso_utenti');
						button.on('click', function(){
														// create the window on the first click and reuse on subsequent clicks
														if(!win){
																	win = new Ext.Window({
																							//layout: 'fit',
resizable: false,
autoHeight: true,
modal:true,




																							title: 'Accesso Utenti',
																							closeAction: 'hide',
																							width:400,
																							height:400,
																							//x: 40,
																							//y: 60,
																							items: {
																									xtype: 'panel',
																									region: 'center',
																									autoLoad : {
																												url : 'js/win_accesso.php',
																												text : "Caricamento ...",
																												scripts : true
																											}
																									}
																							
																						});
																	}
														win.show();
													});
													
						//
						var win2;
						var button = Ext.get('registrazione');
						button.on('click', function(){
														// create the window on the first click and reuse on subsequent clicks
														if(!win2){
																	win2 = new Ext.Window({
																							//layout: 'fit',
resizable: false,
autoHeight: true,
modal:true,




																							title: 'Registrazione Gratuita',
																							closeAction: 'hide',
																							width:400,
																							height:400,
																							//x: 40,
																							//y: 60,
																							items: {
																									xtype: 'panel',
																									region: 'center',
																									autoLoad : {
																												url : 'js/win_registrazione.php',
																												text : "Caricamento ...",
																												scripts : true
																											}
																									}
																							
																						});
																	}
														win2.show();
													});						
 
 						//
						var win3;
						var button = Ext.get('inserisci_usato');
						button.on('click', function(){
														// create the window on the first click and reuse on subsequent clicks
														if(!win3){
																	win3 = new Ext.Window({
																							//layout: 'fit',
resizable: false,
autoHeight: true,
modal:true,




																							title: 'Inserisci Usato',
																							closeAction: 'hide',
																							width:400,
																							height:400,
																							//x: 40,
																							//y: 60,
																							items: {
																									xtype: 'panel',
																									region: 'center',
																									autoLoad : {
																												url : 'js/win_inserisci.php',
																												text : "Caricamento ...",
																												scripts : true
																											}
																									}
																							
																						});
																	}
														win3.show();
													});
 
						//
						var win4;
						var button = Ext.get('certificazione');
						button.on('click', function(){
														// create the window on the first click and reuse on subsequent clicks
														if(!win4){
																	win4 = new Ext.Window({
																							//layout: 'fit',
resizable: false,
autoHeight: true,
modal:true,




																							title: 'Certificazione Usato',
																							closeAction: 'hide',
																							width:400,
																							height:400,
																							//x: 40,
																							//y: 60,
																							items: {
																									xtype: 'panel',
																									region: 'center',
																									autoLoad : {
																												url : 'js/win_certificato.php',
																												text : "Caricamento ...",
																												scripts : true
																											}
																									}
																							
																						});
																	}
														win4.show();
													});

						//
						var win5;
						var button = Ext.get('inserisci_annunci');
						button.on('click', function(){
														// create the window on the first click and reuse on subsequent clicks
														if(!win5){
																	win5 = new Ext.Window({
																							//layout: 'fit',
resizable: false,
autoHeight: true,
modal:true,




																							title: 'Inserisci Annunci',
																							closeAction: 'hide',
																							width:400,
																							height:400,
																							//x: 40,
																							//y: 60,
																							items: {
																									xtype: 'panel',
																									region: 'center',
																									autoLoad : {
																												url : 'js/win_annunci.php',
																												text : "Caricamento ...",
																												scripts : true
																											}
																									}
																							
																						});
																	}
														win5.show();
													});
						//
						var win6;
						var button = Ext.get('cp');
						button.on('click', function(){
														// create the window on the first click and reuse on subsequent clicks
														if(!win6){
																	win6 = new Ext.Window({
																							//layout: 'fit',
resizable: false,
autoHeight: true,
modal:true,




																							title: 'Pannello di Controllo',
																							closeAction: 'hide',
																							width:400,
																							height:400,
																							//x: 40,
																							//y: 60,
																							items: {
																									xtype: 'panel',
																									region: 'center',
																									autoLoad : {
																												url : 'js/win_cp.php',
																												text : "Caricamento ...",
																												scripts : true
																											}
																									}
																							
																						});
																	}
														win6.show();
													});

						//
						var win7;
						var button = Ext.get('hp_privata');
						button.on('click', function(){
														// create the window on the first click and reuse on subsequent clicks
														if(!win7){
																	win7 = new Ext.Window({
																							//layout: 'fit',
resizable: false,
autoHeight: true,
modal:true,




																							title: 'Home Page Privata',
																							closeAction: 'hide',
																							width:400,
																							height:400,
																							//x: 40,
																							//y: 60,
																							items: {
																									xtype: 'panel',
																									region: 'center',
																									autoLoad : {
																												url : 'js/win_hpp.php',
																												text : "Caricamento ...",
																												scripts : true
																											}
																									}
																							
																						});
																	}
														win7.show();
													});
						
 						//
						var win8;
						var button = Ext.get('pubblicita');
						button.on('click', function(){
														// create the window on the first click and reuse on subsequent clicks
														if(!win8){
																	win8 = new Ext.Window({
																							//layout: 'fit',
resizable: false,
autoHeight: true,
modal:true,

																							title: 'La TUA Pubblicità in Incidere.com',
																							closeAction: 'hide',
																							width:400,
																							height:400,
																							//x: 40,
																							//y: 60,
																							items: {
																									xtype: 'panel',
																									region: 'center',
																									autoLoad : {
																												url : 'js/win_pubblicita.php',
																												text : "Caricamento ...",
																												scripts : true
																											}
																									}
																							
																						});
																	}
														win8.show();
													});
						
						
						//link a tutte le inserzioni
						var button = Ext.get('all_usato');
						button.on('click', function(){
														// create the window on the first click and reuse on subsequent clicks
														var redirect = 'index.php?dest=all_usato'; 
														window.location = redirect;
													});
						
 });
