<% if _SESSION["logined"] ~= nil then local admin_nowdir = "/" if _SESSION["admin_basefolder"] ~= nil and _SESSION["admin_basefolder"] ~= "" then admin_nowdir = _SESSION["admin_basefolder"] end if _SESSION["admin_nowdir"] ~= nil and _SESSION["admin_nowdir"] ~= "" then admin_nowdir = _SESSION["admin_nowdir"] end local changedir = _POST["dir"] or "" local CanChangedir = true if _SESSION["admin_basefolder"] ~= nil and _SESSION["admin_basefolder"] ~= "" then if c_StringLength(changedir) < c_StringLength(_SESSION["admin_basefolder"]) then CanChangedir = false end end if changedir ~= "" and c_IsDir(changedir) == true and CanChangedir == true then if _SESSION["admin_readonly"] ~= nil and _SESSION["admin_readonly"] == 1 then else admin_nowdir = changedir rawset(_SESSION,"admin_nowdir",admin_nowdir) SessionModule.save(_SESSION_ID) end end setContentType("text/xml; charset=UTF-8") local strResult = "\r\n" strResult = strResult.."\r\n" strResult = strResult.."\r\n" if admin_nowdir == "/" then for _,root in pairs(c_GetRootDir()) do if root ~= nil then strResult = strResult..""..tostring(root["isdir"]).."" end end else if _SESSION["admin_readonly"] ~= nil and _SESSION["admin_readonly"] == 1 then else for isdir,child in c_GetFileDir(admin_nowdir) do if child ~= nil and child ~= "." and child ~= ".." then strResult = strResult..""..tostring(isdir).."" end end end end strResult = strResult.."\r\n" print(strResult) end %>