Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/jquery/68.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# 超级链接不';无法在IE10和Chrome 28中工作(每次单击Main.aspx中的链接时加载Main.aspx.cs)_C#_Jquery_Asp.net - Fatal编程技术网

C# 超级链接不';无法在IE10和Chrome 28中工作(每次单击Main.aspx中的链接时加载Main.aspx.cs)

C# 超级链接不';无法在IE10和Chrome 28中工作(每次单击Main.aspx中的链接时加载Main.aspx.cs),c#,jquery,asp.net,C#,Jquery,Asp.net,在Main.aspx中,我有: <div data-role="collapsible" data-content-theme="c"> <h3>Sort</h3> <ul data-role="listview" data-inset="true" > <li><a href="Main.aspx?OrderTime">OrderTime</a></li>

在Main.aspx中,我有:

  <div data-role="collapsible" data-content-theme="c">
    <h3>Sort</h3>
    <ul data-role="listview" data-inset="true" >
        <li><a href="Main.aspx?OrderTime">OrderTime</a></li>
                <li><a href="Main.aspx?Person">Person</a></li>
    </ul>
  </div>

     <div data-role="collapsible" data-content-theme="c">
            <h3>Filter</h3>
            <ul data-role="listview" data-inset="true" data-theme="d">
                <li><a href="Main.aspx?1">1 Day</a></li>
                <li><a href="Main.aspx?2">2 Days</a></li>
            </ul>
        </div>

分类
滤器
如果我第一次单击某个链接,将调用Main.aspx.cs中的方法
Page\u Load
。如果我第二次单击同一个链接,我就不会进入Main.aspx.cs(仅当我第一次单击链接时才会调用页面加载)

编辑现在我用FireFox 22.0进行了测试,一切正常。这个问题只发生在IE10上。在我第二次单击链接后,页面不会加载。它记得最后一次点击

Chrome v28也有同样的问题。

我使用Safariv5.1.7进行了测试,一切正常


如果我右键单击并在新选项卡中打开链接,那么IE10也可以使用。为什么右键单击有效而只有左键单击无效?

尝试向页面加载方法添加
IsPostBack
,如下所示:

protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            yourinitcodegoeshere; 
        }
    }

首先,使用此
更改您的html代码,您可以在上阅读更多内容。这就是Internet Explorer的兼容性和版本使用。

问题是,不再使用相同的链接调用页面加载。我在ASP.NET和IE 10中遇到过类似的问题。我希望微软会发送一些补丁。你添加了html5hive.js吗?是的,我添加了。但没有效果。我不知道为什么它对IE不起作用