Foxtable(狐表)用户栏目专家坐堂 → [求助]以http://方式远程升级,多数电脑出现如下问题


  共有2141人关注过本帖树形打印复制链接

主题:[求助]以http://方式远程升级,多数电脑出现如下问题

帅哥哟,离线,有人找我吗?
ytzn
  1楼 | QQ | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:一尾狐 帖子:439 积分:3850 威望:0 精华:0 注册:2012/10/12 5:20:00
[求助]以http://方式远程升级,多数电脑出现如下问题  发帖心情 Post By:2018/3/21 11:07:00 [只看该作者]

腾讯云服务器
图片点击可在新窗口打开查看此主题相关图片如下:微信图片_20180321.jpg
图片点击可在新窗口打开查看

在浏览器中访问

http://ip地址/update/update.txt

http://ip地址/update/update1.zip

通过后又能正常升级了



但下次升级又出现以上问题,请老师解惑,多谢!

 回到顶部
帅哥哟,离线,有人找我吗?
ytzn
  2楼 | QQ | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:一尾狐 帖子:439 积分:3850 威望:0 精华:0 注册:2012/10/12 5:20:00
  发帖心情 Post By:2018/3/21 11:10:00 [只看该作者]

httprequest为:

Functions.Execute("微信头",e)
Dim cmd As New SQLCommand
cmd.ConnectionName = vars("_conn")

'*****************************************************************************************
Dim fl As String = "d:\web\" & e.path
If filesys.FileExists(fl)
    Dim idx As Integer = fl.LastIndexOf(".")
    Dim ext As String  = fl.SubString(idx)
    Select Case ext
        Case ".jpg",".gif",".png",".bmp",".wmf",".js",".css" ,".html",".htm",".zip",".rar",".txt"
            'e.Resp
            e.WriteFile(fl)
            Return '这里必须返回
    End Select
End If




Select Case e.Path
    Case "logon.htm",""
        Functions.Execute("logon",e)
    Case Else
        Dim usernam As String=""
        Dim Password As String=""
        Dim userdeptnam As String=""
        If e.Cookies.ContainsKey("usernam")  Then
            usernam= e.Cookies("usernam") '从cookie中获取用户名
            Password= e.Cookies("password") '从cookie中获取用户密码
            userdeptnam= e.Cookies("userdeptnam")
        End If
        usernam=usernam.trim()
        Password=Password.trim()
        userdeptnam=userdeptnam.trim()
        'essageBox.Show(usernam & "|0|" & Password)
        If Password>"" AndAlso Password.Length>5 AndAlso usernam>"" AndAlso usernam.Length>1  AndAlso userdeptnam>"" AndAlso userdeptnam.Length>1 Then
            Select Case e.Path
                Case "xs_xzml.htm"
                    Functions.Execute("xs_xzml",e)
                Case "xs_list.htm"
                    Functions.Execute("xs_List",e) '分页显示
                Case "xs_edit.htm"
                    Functions.Execute("xs_Edit",e) '生成订单编辑页面
                Case "xs_xzcph.htm"
                    Functions.Execute("xs_xzcph",e) '分页显示
                Case  "xs_fl.htm"
                    Functions.Execute("xs_fl",e)
                Case "xs_sgwyy.htm"
                    Functions.Execute("xs_sgwyy",e) '分页显示
                Case "xs_sgwyyd.htm"
                    Functions.Execute("xs_sgwyyd",e) '分页显示
                Case "xs_sgckyy.htm"
                    Functions.Execute("xs_sgckyy",e) '分页显示
                Case "xs_sgckky.htm"
                    Functions.Execute("xs_sgckky",e)
                Case "xs_sgckyyq.htm"
                    Functions.Execute("xs_sgckyyq",e) '分页显示
                Case "xs_sgckkyq.htm"
                    Functions.Execute("xs_sgckkyq",e)
                Case "xs_sgckwb.htm"
                    Functions.Execute("xs_sgckwb",e)
                Case "xs_sgckbsg.htm"
                    Functions.Execute("xs_sgckbsg",e) '分页显示
                Case "xs_xgch.htm"
                    Functions.Execute("xs_xgch",e)
                Case "xs_ckxs.htm"
                    Functions.Execute("xs_ckxs",e)
                    
                Case "sg_xzml.htm"
                    Functions.Execute("sg_xzml",e)
                Case "sg_ckyy.htm"
                    Functions.Execute("sg_ckyy",e) '分页显示
                Case "sg_ckky.htm"
                    Functions.Execute("sg_ckky",e)
                Case "sg_ckwb.htm"
                    Functions.Execute("sg_ckwb",e)
                    
                    
                Case "qt_xzml.htm"
                    Functions.Execute("qt_xzml",e)
                Case "qt_cwbx.htm"
                    Functions.Execute("qt_cwbx",e)
                Case "qt_cwedit.htm"
                    Functions.Execute("qt_cwedit",e)
                Case "qt_xcjl.htm"
                    Functions.Execute("qt_xcjl",e)
                Case "qt_cwpz.htm"
                    Functions.Execute("qt_cwpz",e)
                Case "qt_cwpz1.htm"
                    Functions.Execute("qt_cwpz1",e)
                Case "qt_cwfl.htm"
                    Functions.Execute("qt_cwfl",e)
                Case "qt_yc.htm"
                    Functions.Execute("qt_yc",e)
                Case "qt_ycedit.htm"
                    Functions.Execute("qt_ycedit",e)
                Case "qt_ycfl.htm"
                    Functions.Execute("qt_ycfl",e)
                Case "qt_wz.htm"
                    Functions.Execute("qt_wz",e)
                Case "qt_wzt.htm"
                    Functions.Execute("qt_wzt",e)
                Case "kxb_sgjl.htm"
                    Functions.Execute("kxb_sgjl",e)
                    
                Case "k_l.htm"
                    Functions.Execute("k_l",e)
                    
                Case "upload.htm"
                    Functions.Execute("upload",e)
                Case "receive.htm"
                    Functions.Execute("receive",e)
            End Select
        Else
            Functions.Execute("logon",e)
        End If
End Select

 回到顶部
帅哥哟,离线,有人找我吗?
有点甜
  3楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:版主 帖子:85326 积分:427815 威望:0 精华:5 注册:2012/10/18 22:13:00
  发帖心情 Post By:2018/3/21 11:14:00 [只看该作者]

单独做一个项目,单独写这个代码

 

Dim fl As String = "d:\web\" & e.path
If filesys.FileExists(fl)
    Dim idx As Integer = fl.LastIndexOf(".")
    Dim ext As String  = fl.SubString(idx)
    Select Case ext
        Case ".jpg",".gif",".png",".bmp",".wmf",".js",".css" ,".html",".htm",".zip",".rar",".txt"
            e.WriteFile(fl)
            Return '这里必须返回
    End Select
End If
 
然后,你测试升级或者执行这个代码下载
 
 

 回到顶部
帅哥哟,离线,有人找我吗?
ytzn
  4楼 | QQ | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:一尾狐 帖子:439 积分:3850 威望:0 精华:0 注册:2012/10/12 5:20:00
  发帖心情 Post By:2018/3/21 11:19:00 [只看该作者]

ok,试试,多谢甜老师。

 回到顶部
帅哥哟,离线,有人找我吗?
ytzn
  5楼 | QQ | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:一尾狐 帖子:439 积分:3850 威望:0 精华:0 注册:2012/10/12 5:20:00
  发帖心情 Post By:2018/3/21 11:53:00 [只看该作者]

重新做项目试了,还是不行,退出再进入,4、5次时有可能成功一次

在命令窗口运行 Network.DownloadFile("http://123.207.xxx.xx/update/update1.zip", "e:\Release.zip")  不成功

但再浏览器中访问

http://ip地址/update/update.txt

http://ip地址/update/update1.zip

都能成功


 回到顶部
帅哥哟,离线,有人找我吗?
aduydgd
  6楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:三尾狐 帖子:681 积分:5332 威望:0 精华:0 注册:2011/12/26 20:43:00
  发帖心情 Post By:2018/3/21 11:55:00 [只看该作者]

你怎么不用系统提供的自动升级功能啊?

 回到顶部
帅哥哟,离线,有人找我吗?
ytzn
  7楼 | QQ | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:一尾狐 帖子:439 积分:3850 威望:0 精华:0 注册:2012/10/12 5:20:00
  发帖心情 Post By:2018/3/21 12:03:00 [只看该作者]

就是用的系统自动升级出现一楼图示情况,以前用的是ftp,只有小部分电脑能升级,所以改用HTTP方式,还是多数电脑升级不了。

再往以前,我用的是xp系统生成的升级文件,没发现升级不了,以后换系统了,win7,win10后出现这个问题

 回到顶部
帅哥哟,离线,有人找我吗?
有点甜
  8楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:版主 帖子:85326 积分:427815 威望:0 精华:5 注册:2012/10/18 22:13:00
  发帖心情 Post By:2018/3/21 12:56:00 [只看该作者]

我测试了一下使用foxtable搭建的http下载正常(本地测试)。foxtable的http不支持多线程,多人同时使用的时候,有可能有问题。但未测试出你说的问题。

 

如果确实有问题,建议还是使用iis单独搭建吧,至少专业一些。


 回到顶部
帅哥哟,离线,有人找我吗?
ytzn
  9楼 | QQ | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:一尾狐 帖子:439 积分:3850 威望:0 精华:0 注册:2012/10/12 5:20:00
  发帖心情 Post By:2018/3/21 14:19:00 [只看该作者]

ok  多谢!

 回到顶部
帅哥哟,离线,有人找我吗?
ytzn
  10楼 | QQ | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:一尾狐 帖子:439 积分:3850 威望:0 精华:0 注册:2012/10/12 5:20:00
  发帖心情 Post By:2018/3/21 19:32:00 [只看该作者]

把升级路径改为 http://123.207.xxx.xx:32177/update/ 都可以升级了

 回到顶部