以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.com/bbs/index.asp)
--  专家坐堂  (http://foxtable.com/bbs/list.asp?boardid=2)
----  js没有跳转  (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=158384)

--  作者:zhangjian222200
--  发布时间:2020/11/18 12:09:00
--  js没有跳转
function validit_per_shouj(){
    var result=submitAjaxFileds("shouji.htm","","isj",false);
    if(result=="OK"){
        alert(\'确认手机完成\');  //这里提示了
        location="index.htm"; //但是这里没有跳转
    }
    else{
        showTopTips("toptip1",result,2000);
        return false;
    }
}

--  作者:有点蓝
--  发布时间:2020/11/18 12:17:00
--  
服务端和index.htm有关的代码?
--  作者:zhangjian222200
--  发布时间:2020/11/18 12:36:00
--  
1.index页面访问正常

2.服务端页面代码:
Dim e As RequestEventArgs = args(0)                             

Dim wb As New weui

wb.AppendHTML("<link rel=\'icon\' href=\'/abc.ico\' Type=\'image/x-icon\' />") \'abc.ico,放到web根目录
wb.AppendHTML("<link rel=\'stylesheet\' href=\'css/weui_xiu.css\'>",True)

wb.AddTopTips("","toptip1","") \'用于显示动态错误提示

With wb.AddTabBar("", "tb1",0)                            \'使用TabBar
    .AddButton("bt1","首页","./images/home_hong.png","/index.htm")  \'.Attribute = ""
    .AddButton("bt2","发布","./images/fabu_zi.png","/per_fabu.htm")
    .Addpage("bt3","当前","./images/dangqian_zi.png")
    .AddButton("bt5","我的","./images/user_hong.png","/personal.htm")
End With

wb.AddForm("bt3","form1","per_shouj.htm").Attribute=""
With wb.AddInputGroup("form1","ipg1","确认手机号+服务协议")
        With .AddInputCell("ic1")  \'通过InputCell增加输入框(1表示突出显示,2表示红色警示图标)
            .AddLabel("lsj","手机号码",0)  \'增加标签(0显示在左边)
            .AddInput("isj","text",1).PlaceHolder= "请输入手机号"  \'增加输入框(0靠左显示,1居中显示,2靠右显示)
        End With
        With .AddInputCell("ic2")
            .AddLabel("lyz","验证码",0)
            .AddInput("iyz","text",1).PlaceHolder= "请输入验证码"
            .AddVcodeButton("vyz","获取验证码",2).Attribute=""      \'这里正常,内容是:引用ajaxform_per_shoujyz.js的内容
        End With
        .AddSwitch("fuwuxieyi","同意协议").Value = "是"
        With wb.AddButtonGroup("form1","btg1",True)
            .Add("btn1", "点此提交 不可更改", "submit")
            .Add("btn2", "服务协议", "","/protocol.htm").Kind = 1
        End With
End With
wb.AppendHTML("<script src=\'./lib/ajaxform_per_shoujyz.js\'></script>") \'引入脚本文件
wb.AppendHTML("<script src=\'./lib/ajaxform_per_shouj.js\'></script>") \'引入脚本文件  ’见1楼
e.WriteString(wb.Build)
e.Handled = True \'通知系统异步函数执行完毕,可以关闭信道
[此贴子已经被作者于2020/11/18 12:43:25编辑过]

--  作者:有点蓝
--  发布时间:2020/11/18 14:21:00
--  
上面的函数代码就是index.htm页面的代码?httprequset访问index.htm的代码看看
--  作者:zhangjian222200
--  发布时间:2020/11/18 15:32:00
--  
上次的函数代码就是index.htm,但是删除了一部分。

[此贴子已经被作者于2020/11/18 23:18:30编辑过]

--  作者:有点蓝
--  发布时间:2020/11/18 15:40:00
--  
httprequest完整代码发生来看看。1楼的js函数在哪里调用的?
--  作者:zhangjian222200
--  发布时间:2020/11/18 19:24:00
--  
上面是用微信开发者工具测试的,没有跳转。

改用手机测试,跳转正常。

--  作者:有点蓝
--  发布时间:2020/11/19 8:35:00
--  
开发者工具右边有没有提示什么错误?