eccolo, il nome album che recupero con il request.querystring aveva nel nome il carattere &
codice:
%
Dim web
web = Request.ServerVariables("server_name")
web = MID(web,5)
web = Replace(web, "." , "")
dim fs,fo,x,nome
set fs=Server.CreateObject("Scripting.FileSystemObject")
set fo=fs.GetFolder("d:\inetpub\webs\" & web & "\public\album\" & request.querystring("nome_album") & "\")
set custRs = Server.CreateObject("ADODB.Recordset")
custRs.Fields.Append "nome", 200, 300 ' adVarChar
custRs.Fields.Append "data", 7 ' Date
custRs.Fields.Append "dimensione", 2, 4 ' smallint
custRs.Open
risultatiPerPagina = 10
pagina = Request.queryString("pagina")
if len(pagina) > 0 and isNumeric(pagina) then
pagina = cLng(pagina)
else
pagina = 1
end if
if pagina < 1 then pagina = 1
questaPagina = request.serverVariables("PATH_INFO")
for each x in fo.files
custRs.AddNew
custRs("nome") = x.Name
custRs("data") = x.DateCreated
custRs("dimensione") = x.Size / 1024
custRs.update
next
custRs.Sort = "data Desc"
If custRs.EOF Then
%>
Non ci sono foto in questa cartella
<%
else
if not custRs.eof then
custRs.pageSize = risultatiPerPagina
custRs.absolutePage = pagina
for r = 1 to risultatiPerPagina
if not custRs.eof then
%>
ecco le foto
<%
custRs.MoveNext
else
exit for
end if
next
end if
%>