asp.net 内容页post跳转到其他网页
代码如下:求指导<%@PageLanguage="C#"MasterPageFile="~/CustomerInfo/MasterPage.master"AutoEven...
代码如下: 求指导
<%@ Page Language="C#" MasterPageFile="~/CustomerInfo/MasterPage.master" AutoEventWireup="true" CodeFile="Accsum.aspx.cs" Inherits="ReportAll_Accsum" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
<script src="../JS/jquery-1.4.4.min.js" type="text/javascript"></script>
<script type="text/javascript" language="javascript">
window.onload = function () {
var text = document.getElementById("<%=this.cusid.ClientID %>").value;
if (text == "0" || text == "" || text == "全部") {
alert("客户不唯一,请重新选择");
} else {
var cus = $("#<%=this.cusid.ClientID %>").val();
var cid = $("#<%=this.cid.ClientID %>").val();
var htps = $("#<%=this.http.ClientID %>").val();
var url="http://"+htps+":8080/WebReport/ReportServer?reportlet=/accsum_n1.cpt&customer=" + cus + "&cid=" + cid + "";
window.open(url, "发生额及余额表", ""); //怎样post跳转
}
}
</script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
<asp:HiddenField ID="cusid" runat="server" />
<asp:HiddenField ID="cid" runat="server" />
<asp:HiddenField ID="http" runat="server" />
</asp:Content> 展开
<%@ Page Language="C#" MasterPageFile="~/CustomerInfo/MasterPage.master" AutoEventWireup="true" CodeFile="Accsum.aspx.cs" Inherits="ReportAll_Accsum" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
<script src="../JS/jquery-1.4.4.min.js" type="text/javascript"></script>
<script type="text/javascript" language="javascript">
window.onload = function () {
var text = document.getElementById("<%=this.cusid.ClientID %>").value;
if (text == "0" || text == "" || text == "全部") {
alert("客户不唯一,请重新选择");
} else {
var cus = $("#<%=this.cusid.ClientID %>").val();
var cid = $("#<%=this.cid.ClientID %>").val();
var htps = $("#<%=this.http.ClientID %>").val();
var url="http://"+htps+":8080/WebReport/ReportServer?reportlet=/accsum_n1.cpt&customer=" + cus + "&cid=" + cid + "";
window.open(url, "发生额及余额表", ""); //怎样post跳转
}
}
</script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
<asp:HiddenField ID="cusid" runat="server" />
<asp:HiddenField ID="cid" runat="server" />
<asp:HiddenField ID="http" runat="server" />
</asp:Content> 展开
3个回答
展开全部
用ajax提交噻
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
form表单action要提交地址,默认是本页
追问
这我知道,我这是一个用了母版页的内容页,如果母版页中存在了 from,内容页就不能再有,所以说不用 from, 怎么post页面跳转呢?
追答
post和get是对于表单的,你不提交表单单纯跳转可以用location = "url",js跳转
本回答被提问者采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询