复制代码 代码如下:
<%
'+-----------------------------------+
'| 变量设置
'+-----------------------------------+
cTitle = "所有上传图片(注:以下为图片文件夹下面所有图片,并非全部为有效图片!)" '名字
cPicType = "jpeg,jpg,gif,png,bmp" '图片类型 (使用","将图片格式分开)
cHeight = 120 '缩图高度
cWidth = 120 '缩图宽度
cEachLineMax = 5 '每行显示图片数
cEachPageMax = 20 '每页显示图片数目
pic_path="/uploadpic/" '设定图片所在路径
'+-----------------------------------+
'| 定义函数
'+-----------------------------------+
Function getExt(name)
getExt = right(name, 3)
End Function
Function isPIC(fileName, picType)
ext = getExt(fileName)
isPIC = False
typeList = split(picType, ",")
For ii = LBound(typeList) To UBound(typeList)
If UCase(ext) = UCase(typeList(ii)) Then
isPIC = True
Exit For
End If
Next
End Function
Function pageBar(page, pageTotal)
response.Write "[ <A HREF="&Request.ServerVariables("SCRIPT_NAME")&"?page=" & (page - 1) & " title=上一页>上一页</A> ] "
response.Write "<A HREF="&Request.ServerVariables("SCRIPT_NAME")&"?page=1 title=首页><< </A>"
i = pageStart
Do while i < page
response.Write "<A HREF="&Request.ServerVariables("SCRIPT_NAME")&"?page=" & i & " title=""第 " & i & " 页"">[" & i & "]</A> "
内容版权声明:除非注明,否则皆为本站原创文章。