
01/03/2002, 19:27
|
| | Fecha de Ingreso: octubre-2000 Ubicación: Juarez, Chih.
Mensajes: 161
Antigüedad: 24 años, 6 meses Puntos: 0 | |
Re: Buscador basado en los Meta Tags <%
'continua
Function Buscar_aqui(PathSpec,Exts,clave)
If right(PathSpec,8)<>"_vti_cnf" then
Session("Totales") = Session("Totales") + 1
If Session("Totales") > Ubound(Resultados,1) then
Exit Function
End if
Set Fso = CreateObject("Scripting.FileSystemObject" ;)
Set FolderInfo = Fso.GetFolder(PathSpec)
Set FileList = FolderInfo.Files
resx = 0
For Each File in FileList
Name = Cstr(File.Name)
FileName = UCase(Name)
For i = 0 to UBound(Exts)
If Instr(FileName,Ucase(Exts(i))) Then
de_esta_pagina = FormatURL(PathSpec) & "/" & FileName
If len(obtener_metas(de_esta_pagina))>1 then
Session("Encontrados") = Session("Encontrados") + 1
Session("Coincidencias")= 0
Resultados(resx,0) = Obtener_titulo(de_esta_pagina) & "<br>"
metas = obtener_metas(de_esta_pagina)
If len(metas)>0 then
j2 = Split(metas,"|",-1,1)
k = 1
Metas = Ubound(j2)
For m=0 to Ubound(j2)
Resultados(resx,k) = j2(m)
k = k + 1
Next
End if
Resultados(resx,metas+1) = "<b>Url:</b> " & "<A HREF=""" & FormatURL(PathSpec) & "/" & FileName & """>" & Lcase("http://" & Request.ServerVariables("HTTP_HOST") & FormatURL(PathSpec) & "/" & FileName) & "</A><br>"
Resultados(resx,metas+2) = "Se encontrarón <b>" & Session("Coincidencias") & "</b> ocurrencias de la clave en el título ó los meta tags de esta página."
resx = resx + 1
End if
End If
Next
Next
Set f = Fso.GetFolder(PathSpec)
Set fc = f.SubFolders
For Each Folder in fc
Call Buscar_aqui(PathSpec & "\" & Folder.Name,Exts,clave)
Next
End if
End Function
%> |