<style>
body{text-align:center;font:12px #000080 ;}
#dir{float:left;width:300px;border:#0000ff 1px solid;text-align:left;margin:5px 5px 20px 5px;padding:5px 5px 5px 5px;color:#000080;font:14px arial,verdana,sans-serif;}
#main h1{font-size:16px;font-weight:bold;color:#a00000;}
#filed{float:right;width:420px;border:#0000ff 1px solid;text-align:left;margin:5px 5px 20px 5px;padding:5px 5px 5px 5px;color:#000080;font:14px arial,verdana,sans-serif;}
</style>
<SCRIPT LANGUAGE="JavaScript">
<!--
function ctrla()
{
var e = fmfile.cfile;
if (document.fmfile.cfileall.checked)
{
//alert("");
for( var i = 0; i < e.length; i++ )
e[i].checked=true;
//alert("");}
}
else
{
for( var i = 0; i < e.length; i++ )
e[i].checked=false;
}
}
//-->
</SCRIPT>
<%
Cdir=replace(request("currentdir"),"'","")
Nextdir=replace(request("nextdir"),"'","")
if cdir="" then
fldspec=server.mappath("html.asp")
posb=instrrev(fldspec,"\",-1,1)-1
fldspec=left(fldspec,posb)
response.write fldspec&"------"&posb
else
if nextdir="" then
posb=instrrev(cdir,"\",-1,1)-1
if posb=-1 then
fldspec=cdir
else
fldspec=left(cdir,posb)
response.write fldspec&"------:"&posb
'response.end
end if
else
fldspec=cdir+"\"+nextdir
response.write fldspec
end if
end if
call showfolderlist(fldspec)
Sub ShowFolderList(folderspec)
Dim fs, f, f1, fc, s
Set fs = CreateObject("Scripting.FileSystemObject")
Set f = fs.GetFolder(folderspec)
Set fc = f.Files
set objSubFolders=f.Subfolders
response.write"<div id=dir>"
response.write"请选择目录:"
response.write"<B><a href=html.asp?currentdir="&folderspec&">..</a></B><BR>"&vbcrlf
for each subfolders in objsubfolders
subfoldername=subfolders.name
subfoldername=subfoldername
response.write"<a href=html.asp?currentdir="&escape(folderspec)&"&nextdir="&escape(subfoldername)&">"&subfoldername&"</a><BR>"&vbcrlf
'response.write subfoldername
next
if dirm="/" then
dirm=""
end if
response.write"<a href='javascript:history.back(-1)'>返回</a>"
response.write"</div>"
response.write "<div id=filed><form name=fmfile method=post action=cast.asp >"
response.write "<input type=submit name=action value=转换><input type=submit name=action value=删除><BR>s:<input type=text name=StartString>e:<input type=text name=EndString><BR>sby:<input type=text name=StartString>eby:<input type=text name=EndString><BR>"
response.write "<input type=checkbox name=cfileall onclick=javascript:ctrla()>[全选]<BR>"
For Each f1 in fc
s = f1.name
response.write "<input type=checkbox name=cfile value="&s&">"&s&""&vbCrLf&"<BR>"
Next
response.write "</form></div>"
End Sub
%>