ASP

ASP Variables Strings Form Arrays 2D Array Loop IF Cookies Dates Dictionaries SQL Numbers Files JSON Database Regular Expression ExecuteGlobal Recordset ServerVariables Bugs ADO AJAX XML Chilkat
O O

Weather Controls

Time Of Day
Rain
Wind Speed
Wind Direction
Clouds

ASP : Files

2017-11-07

default.asp

This will display all files and folders in a directory and create a link to them.

<% 
strPath = "/admin/dev/library"
FilePath=Server.MapPath(strPath) & ""

set fso=Server.CreateObject("Scripting.FileSystemObject")
set folder=fso.GetFolder(FilePath)

for each page in folder.files
    Response.Write("<a href='" & page.name & "'>" & page.name & "</a><br>")
next

set fso=nothing
set folder=nothing
%>

Tell me what path I'm currentl in

tbPrint Request.ServerVariables("PATH_TRANSLATED")