最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
asp url转换函数
时间:2022-07-02 22:44:11 编辑:袖梨 来源:一聚教程网
' 函数名:RelativePath2RootPath
' 作 用:转为根路径格式
' 参 数:url ----原URL
' 返回值:转换后的URL
'================================================
Function RelativePath2RootPath(url)
Dim sTempUrl
sTempUrl = url
If Left(sTempUrl, 1) = "/" Then
RelativePath2RootPath = sTempUrl
Exit Function
End If
Dim sFilePath
sFilePath = Request.ServerVariables("SCRIPT_NAME")
sFilePath = Left(sFilePath, InstrRev(sFilePath, "/") - 1)
Do While Left(sTempUrl, 3) = "../"
sTempUrl = Mid(sTempUrl, 4)
sFilePath = Left(sFilePath, InstrRev(sFilePath, "/") - 1)
Loop
RelativePath2RootPath = sFilePath & "/" & sTempUrl
End Function
相关文章
- 《满庭芳宋上繁华》玩家自制地图添加方法 08-02
- Tether计划推出华尔街专属稳定币 强化美国市场布局 08-02
- 《满庭芳宋上繁华》存档位置介绍 08-02
- 《地下城堡4》零氪墓穴145层攻略 08-02
- 2025年8月值得关注的3个潜力小众代币 08-02
- 《地下城堡4》阴魂大厅Boss魔君打法攻略 08-02