var item = new Array();

EcranHaut = screen.height;
EcranLarg = screen.width;

c=0; item[c]=new Array("tatoo.php?v=t&a=c","","tarifs","tarifs, sous, argent, combien, çoûte, piercing, tatouage, tatoo","(nos tarifs...)");

c=1;item[c]=new Array("tatoo.php?v=t&a=l","","lieu","adresse,lieu,endroit,géographie,où,situation, téléphone,tel,commande,commander,commandes,contact,contacts,e-mail,mail","(où nous trouver...)");

c=2;item[c]=new Array("tatoo.php?v=t&a=g","","galerie","tattoo, photos, images, galerie, voir, visionner, diaporama","(voir les photos...)");

c=3;item[c]=new Array("tatoo.php?v=t&a=u","","ustensiles","ustensiles, outils, aiguilles, pigments, encres, matériel, hygiène, stérilisation","(les outils,les pigments...)");

page="<html><head><title>résultats</title><style type='text/css'><!-- a:link,a:active,a:visited { text-decoration:none; } a:hover { text-decoration: underline; } //--></style></head><body bgcolor='3f8caa' text='2d4f6a' link='b2dcda' vlink='b2dcda' alink='b2dcda'><style>BODY{scrollbar-face-color:#3f8caa;scrollbar-arrow-color:#707078;scrollbar-track-color:#707078;scrollbar-shadow-color:#707078;scrollbar-highlight-color:#707078;scrollbar-3dlight-color:#707078;scrollbar-darkshadow-Color:#707078;} </style><a href='javascript:self.close()'><font face=verdana size=1>fermer</a><br>";

function search(frm) {
txt = frm.srchval.value.split(" ");
fnd = new Array(); total=0;
for (i = 0; i < item.length; i++) {
fnd[i] = 0; order = new Array(0, 4, 2, 3);
for (j = 0; j < order.length; j++)
for (k = 0; k < txt.length; k++)
if (item[i][order[j]].toLowerCase().indexOf(txt[k]) > -1 && txt[k] != "")
fnd[i] += (j+1);
}


function show(which,wind,num) {
 link = item[which][1] + item[which][0]; 
 line = "<tr><td><p align='center'><a href='"+link+"' target='_blank'><font face=verdana size=2>"+item[which][2]+"</font></a><br><font face=verdana size=2>";
 line +=item[which][4] +"</p></td></tr>";
 wind.document.write(line);
 return 1;
}

 if((txt == 'recherche')||(txt == '')){        alert('veuillez entrer un mot clef'); }        else{
win = window.open('','','width=200,height=400,left=100,top=100,scrollbars=1');
win.document.write(page);
win.document.write("<p align=center><font face=verdana size=2>résultats pour <b> '"+txt+"'</b><hr><br>");

for (i = 0; i < fnd.length; i++) {
  n = 0; w = -1;
  for (j = 0;j < fnd.length; j++)
    if (fnd[j] > n) { 
      n = fnd[j]; w = j; 
    };
    if (w > -1) total += show(w, win, n);
    fnd[w] = 0;
  }
 win.document.write("<br><p align=center><hr><font face=verdana size=2>Pages trouvée(s): "+total+"");
  win.document.close();
}

}

