綠色資(zī)源網:您身邊最放心的安全下載站! 最新軟件|熱門排行|軟件分類|軟件專題|廠商大全

綠色資源網

技術教程
您的位置:首頁(yè)網絡編程Asp編程 → asp中將相對路徑轉換為絕對路徑的函數

asp中將相對路徑轉換為絕對路徑的函數

我要評論 2011/05/28 21:01:20 來源:綠色資源網 編輯:ynaad.com [大(dà) ] 評論(lùn):0 點(diǎn)擊:345次

'================================================
' 函數名:ChkMapPath
' 作 用:相對路徑轉(zhuǎn)換(huàn)為絕對路(lù)徑
' 參 數:strPath ----原路徑
' 返回(huí)值:絕對路(lù)徑
'================================================
Function ChkMapPath(ByVal strPath)
Dim fullPath
strPath = Replace(Replace(Trim(strPath), "/", "\"), "\\", "\")

If strPath = "" Then strPath = "."
If InStr(strPath,":\") = 0 Then
fullPath = Server.MapPath(strPath)
Else
strPath = Replace(strPath,"..\","")
fullPath = Trim(strPath)
If Right(fullPath, 1) = "\" Then
fullPath = Left(fullPath, Len(fullPath) - 1)
End If
End If
ChkMapPath = fullPath
End Function

關鍵詞:asp

閱讀本文(wén)後(hòu)您有什麽感想? 已有 人給出評價!

  • 1 歡迎喜歡
  • 1 白癡
  • 1 拜托
  • 1 哇
  • 1 加油
  • 1 鄙(bǐ)視(shì)
免费人欧美成又黄又爽的视频丨一本色道久久88综合日韩精品丨国产专区日韩精品欧美色丨午夜无遮挡男女啪啪视频丨国产欧美日韩综合精品一区二区丨亚洲精品无码不卡在线播HE丨亚洲精品国产精品国自产观看丨日韩国产高清av不卡