<%@ page language="C#" autoeventwireup="true" inherits="ims.web.Prompt, ims.web" enableviewstatemac="false" enableEventValidation="false" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" id="Prompt">
<head runat="server">
    <title></title><meta http-equiv="X-UA-Compatible" content="IE=edge" />
</head>
<body>
    <form id="form1" runat="server">
        <asp:ScriptManager ID="sm" runat="server">
            <Scripts><asp:ScriptReference Name="MicrosoftAjax.js" ScriptMode="Auto" Path="~/js/MsAjax.js"/><asp:ScriptReference Name="MicrosoftAjaxWebForms.js" ScriptMode="Auto" Path="~/js/MsAjax.js"/></Scripts>
        </asp:ScriptManager>
        <ims:Pop runat="server" ID="box" ShowCloseButton="false" InitVisible="true" ShowCancelButton="false" Width="380" OkButtonText="返回" OnOkClientClick="toBack();" ShowProgress="false">
            <ContentTemplate>
			    <table cellspacing="0" class="fixedLayout"><tr><td id="tdIcon"><asp:Image runat="server" ID="imgIcon" /></td>
			        <td ID="content" runat="server">
                    </td></tr>
			    </table>
            </ContentTemplate>
        </ims:Pop>
        <script src="js/comm.js"></script>
        <script>
            $(function () {
                if (inIframe()) {
                    var pop = $("#box_popup");
                    var x = (document.documentElement.clientWidth - pop.outerWidth(false)) / 2, y = (document.documentElement.clientHeight - pop.outerHeight(false)) / 2;
                    x = (Math.max(2, x) + $(window).scrollLeft()) + "px";
                    y = (Math.max(2, y) + $(window).scrollTop()) + "px";
                    pop.css({ left: x, top: y });
                    $("body").height(pop.offset().top + pop.outerHeight(true) + 18);
                }
            });
            function AfterReged() {
                setTimeout(function () {
                    if (parent == self) {
                        location = 'default.aspx';
                    } else {
                        parent.location = parent.location;
                    }
                },3000);
            }
            function toBack() {
                if (inPopup()) {
                    if (getPage(parent.location.href) == "table.aspx" && referrerIs("edit.aspx")) {
                        parent.dataChanged = true;
                    }
                    setTimeout(parent.$.colorbox.close, 0);
                } else {
                    if (window.dialogArguments || opener) { //如果当前页面位于弹出窗口（不是Colorbox弹出）中，则关闭窗口
                        window.close();
                    } else {
                        history.go(getUrlParam("type") == "Success" ? -2 : -1);
                    }
                    return false;
                }
            }
        </script>
    </form>
</body>
</html>