老师,以下服务端,在本地用127.0.0.1可以正常操作,但上传到阿里云就不可以,
应该如何排查,用127.0.0.1:8010 也不行
HttpRequest
Functions.Execute("ErrFileWite",
"e.Path =" & e.Path & ",e.Host =" & e.Host
& ",e.Port = " & e.Port & ", 完整地址 = " &
e.Request.URL.ToString)
Dim wb As New weui
'~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Dim SPath As
String = e.Path
Dim err As Integer
If SPath >
"" Then
If SPath.Contains(".rar") OrElse
SPath.Contains(".pdf") Then
Dim fl As String =
Vars("WbPath") & "\SKFile\" & Spath
Functions.Execute("ErrFileWite", "SPath.Contains =
true----fl =" & fl)
If FileSys.FileExists(fl) Then
e.WriteFile(fl)
Else
err = 1
End If
Else
Functions.Execute("ErrFileWite", "SPath.Contains =
false---" & e.Path)
err = 1
End If
Else
err = 1
End If
If err > 0 Then
e.WriteString("欢迎登录网站!")
err = 0
End If
启动_But开启服务_Click
Dim BtName As
String = e.Sender.Text
If e.Sender.Text =
"开启服务" Then
HttpServer.Prefixes.Add("http://*/")
HttpServer.Prefixes.Add("http://*:8010/")
HttpServer.WebPath =
Vars("WbPath")
HttpServer.Start()
e.Form.Controls("Label1").text =
e.Sender.text
e.Sender.Theme = "Office2010Red"
e.Sender.Text = "停用服务"
e.Form.Controls("Label1").text =
"数据服务已经启用!"
e.Form.Controls("Label1").ForeColor = Color.Green
ElseIf
e.Sender.Text = "停用服务" Then
HttpServer.Close()
e.Sender.Theme = "ShinyBlue"
e.Sender.Text = "开启服务"
e.Form.Controls("Label1").text =
"数据服务已经停用!"
e.Form.Controls("Label1").ForeColor
= Color.red
End If
Functions.Execute("ErrFileWite",
Vars("WbPath"))