开发者

ASP.NET colorbox not refreshing destination page

I have an asp.net page that has a hyperlink that opens an asp.net page in a colorbox jQuery window.

<asp:HyperLink ID="hl1" runat="server" CssClass="info_colorbox">

Then I have the javascript to open the jQuery colorbox:

<script>
 开发者_开发知识库   $(document).ready(function () {
        $(".info_colorbox").colorbox({ width: "900px", height: "600px" });
    });

    function pageLoad(sender, args) {
        if (args.get_isPartialLoad()) {
            $(".info_inscriptions").colorbox({ width: "900px", height: "600px" });
        }
    }
</script>

I set up the Navigation page in the codebehind because it changes depending on other controls.

The colorbox window works fine, the problem is the destination page is not refreshing its contents. The destination page has a formview with some info it reads from a database. If I load the page separately it works fine and loads the latest info from the database. The problem is when I open in a colorbox window is not reading the latest info.


You say you are opening a page, are you sure you shouldn't be using an iframe to display it? If you really are just opening an html snippet, then you can turn off jQuery's ajax caching. Example:

$.ajaxSetup ({
    cache: false
});
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜