<% DIM view, ID view=Request.QueryString("view") %> G A T T I D E L T O R R I N O . i t

g a t t i d e l t o r r i n o . i t

 
<% i=0 For Each objItem In objFolder.Files %> <% i=i+1 IF i=4 THEN i=0 %> <%END IF NEXT %>

<% IF view="" THEN%> <% Dim dirname, mypath, fso, folder, filez, FileCount %> <% Set fso = CreateObject("Scripting.FileSystemObject") Set folder = fso.GetFolder(server.mappath(dirname)) Set filez = folder.Files FileCount = folder.Files.Count ' This function takes a filename and ret ' urns the appropriate image for ' that file type based on it's extension ' . If you pass it "dir", it assumes ' that the corresponding item is a direc ' tory and shows the folder icon. %> <%' Now To the Runtime code: Dim strPath 'Path of directory to show Dim objFSO 'FileSystemObject variable Dim objFolder 'Folder variable Dim objItem 'Variable used To Loop through the contents of the folder ' You could just as easily read this fro ' m some sort of input, but I don't ' need you guys and gals roaming around ' our server so I've hard coded it to ' a directory I set up to illustrate the ' sample. ' NOTE: As currently implemented, this n ' eeds to end with the / strPath = mypath ' Create our FSO Set objFSO = Server.CreateObject("Scripting.FileSystemObject") ' Get a handle on our folder Set objFolder = objFSO.GetFolder(Server.MapPath(strPath)) ' Now that I've done the SubFolders, do ' the files! i=0 For Each objItem In objFolder.Files i=i+1 NEXT %>


ingrandisci
ingrandisci
<% Set objItem = Nothing Set objFolder = Nothing ' All done! Kill off the object variable ' s. Set objFSO = Nothing %> <%END IF%> <%IF view="ShowPic" THEN imageURL=Request.QueryString("ID")%>




galleria foto | homepage
<%END IF%>