-
加入我們
-
VIP定制
-
求關注
Thank you for visiting
029-81773686
全網(wǎng)開發(fā)&整合營銷服務商
CopyRight
?HOOBOO All rights reserved
2016.05.16
Private Function CheckOrCreatePath( ByVal path )
Set fs = Server.CreateObject("Scripting.FileSystemObject")
Dim parts
parts = Split( path, "" )
For Each part in parts
path = path + part + ""
If fs.FolderExists( path ) = False Then
fs.CreateFolder( path )
End If
Next
End Function
修改為
Private Function CheckOrCreatePath( ByVal path )
Set fs = Server.CreateObject("Scripting.FileSystemObject")
Dim parts
Dim root : root = Server.mappath("/") & ""
parts = Split( Replace(path, root, ""), "" )
path = root
For Each part in parts
path = path + part + ""
If fs.FolderExists( path ) = False Then
fs.CreateFolder( path )
End If
Next
End Function
即可正常上傳。如下圖:
CopyRight ? 西安宏博網(wǎng)絡科技有限公司 備案號:陜ICP備10007014號-8 站點地圖 免責聲明:本網(wǎng)站部分資源來源于網(wǎng)絡,如有侵權,請聯(lián)系我們告知刪除,我們將會盡快處理,謝謝!本站不承擔任何法律責任。