<% main() Sub main() If Not(InternetCheck()) Then Exit Sub End If ' If Not(VisitorCheck()) Then ' Exit Sub ' End If If Not(ShopAdminCheck()) Then Exit Sub End If 'Response.Write(GB_ShopAdmin) 'Exit Sub Dim Query Dim Content Dim Content2 Dim fs, obj Dim FileDir Dim a, b, f1, fsize1, l1, FileName a=Request.TotalBytes On Error Resume Next Err.Clear() b=Request.BinaryRead(a) If Err.Description <> "" Then Response.Write("エラーが発生しました。
ファイルサイズが大きすぎる可能性があります。

") Response.Write("エラーコード:") Response.Write(Err.Description) Response.Write("

") Response.Write("戻る") Exit Sub End If On Error Goto 0 set obj = server.createobject("basp21") Dim ActShopID ActShopID = obj.Form(b, "ActShopID") If LCase(ActShopID) <> LCase(GB_ShopAdmin) Then Response.Write("別のウィンドウまたは別のタブページで現在と異なるIDでログインしました。
" & vbCrLf) Response.Write("同一PC上で複数のIDでログインすることはできません。
" & vbCrLf) Response.Write("
" & vbCrLf) Response.Write("戻る" & vbCrLf) Exit Sub End If fsize1 = obj.FormFileSize(b,"UpFile") Dim Folder Folder = obj.Form(b,"Folder") Dim HomepageFolder HomepageFolder = "" & HomeAliasSL & "shop/" & GB_ShopAdmin '不正なフォルダにアップされないようここで管理サイトを特定する Dim UpFolder UpFolder = HomepageFolder & Folder f1 = obj.FormFileName(b,"UpFile") FileName = Mid(f1, InStrRev(f1, "\") + 1) 'パスからファイル名を取り出す Dim FileExt FileExt = Mid(FileName, InStrRev(FileName, ".") + 1) 'ファイル名から拡張子を取り出す If LCase(FileExt) = "asp" Or LCase(FileExt) = "aspx" Then Response.Write("サーバーサイドスクリプトはアップロードできません。

") Response.Write("戻る") Exit Sub End If l1 = obj.FormSaveAs(b, "UpFile", Server.MapPath(UpFolder) & "\" & FileName) Response.Redirect("shopsite.asp?ActShopID=" & ActShopID & "&FileName=" & FileName & "&Folder=" & Folder) '以下非利用 %>
 

<% End Sub %>