// ActionScript Document
var TestoIniziale="";
var pagine = [
   ["Home","Index.htm","Index.htm"],
    ["Vendite Pavia","Compravendite.htm","Index.htm"],
    ["Vendite Fuori Pavia","CompravenditeFuoriPavia.htm","Index.htm"],
    ["Scheda immobile","SchedaImmFP.htm","CompravenditeFuoriPavia.htm"],
	["Video immobile affitto","SchedaVClip.htm","Locazioni.htm"],		
    ["Affitti in Pavia e provincia","Locazioni.htm","Index.htm"],
    ["Cantiere di Broni","CantiereBroni.htm","CompravenditeFuoriPavia.htm"],
    ["Cantiere di Gerenzago","CantieriGerenzago.htm","CompravenditeFuoriPavia.htm"],
    ["Cantiere di Valle Salimbene","CantiereValle.htm","CompravenditeFuoriPavia.htm"],
    ["Per Acquistare","Acquisto.htm","Index.htm"],
    ["Per Affittare","Affitto.htm","Index.htm"],
    ["Per Vendere","Vendo.htm","Index.htm"],	
    ["Richiesta","CercoCasa.htm","Index.htm"],
    ["Valutazione gratuita","Valutazione.htm","Index.htm"],	
    ["Privacy","Privacy.htm","Index.htm"],			
    ["Mappa del sito","MappaDelSito.htm","Index.htm"],
	    ["Indice ISTAT","istat.htm","Index.htm"],
		["Interessi legali","interessilegali.htm","Index.htm"],
	    ["Tasso di riferimento","tassoufficialedisconto.htm","Index.htm"],
    ["Contattaci","Contattaci.htm","Index.htm"],	
	    ["Le notizie del giorno","news.htm","Index.htm"],
	    ["Edicola on line","edicola.htm","link.htm"],
	    ["Orario dei treni","orariotreni.htm","link.htm"],
	    ["Estrazioni del Superenalotto","superenalotto.htm","link.htm"],
	    ["Estrazioni del Lotto","lotto.htm","link.htm"],				
	    ["Link utili","link.htm","Index.htm"],
	    ["Scambio link","scambiolink.htm","Index.htm"],
	    ["Contratto locazione uso abitativo","contrattoaffittousoabitativo.htm","link.htm"],
	    ["pagina 2","contrattoaffittousoabitativo2.htm","contrattoaffittousoabitativo.htm"],																					
	  
	    ["Ricette","ricettecucina.htm","Index.htm"],  
		
		  ["Calcola la rata del mutuo","CalcolaMutuo.htm","Index.htm"]


 ];

	
var percorso="";
// estrae la stringa prima di ?
var fn=new Array();
var filename = document.URL.replace(/\\/g,"/");
  fn=filename.split("?");
  filename=fn[0]


var nolink=0;

CercaSitePointer(filename.substr(filename.lastIndexOf("/")+1));
document.write("<span class='PLink'>"+TestoIniziale+percorso.substr(3)+"</span>");

function CercaSitePointer(str)
 {
   for (var i=0 ; i<pagine.length ; i++)
      if (pagine[i][1] == str)
	  {
	  if (nolink ==0)//pagina da non linkare
	    { nolink ++; 
		  percorso=" / "+pagine[i][0]+percorso;
		    if (pagine[i][2] != str)
          CercaSitePointer(pagine[i][2]);
		}
	   else
            {
         percorso=" / <a href='"+str+"' class='PLink'>"+pagine[i][0]+"</a>"+percorso;
        if (pagine[i][2] != str)
                     CercaSitePointer(pagine[i][2]);
            }
	  }
   };
