<%@ page language="C#" autoeventwireup="true" inherits="ims.mail, ims.web" enableviewstatemac="false" enableEventValidation="false" %>
<!DOCTYPE html>
<html id="mail">
<head runat="server">
    <title>发送邮件</title><meta http-equiv="X-UA-Compatible" content="IE=edge" /><meta name="viewport" content="width=device-width,initial-scale=1">
</head>
	<body>
		<form id="form1" method="post" runat="server">
        <asp:ScriptManager ID="sm" runat="server" OnAsyncPostBackError="AsyncError">
            <CompositeScript Path="js/msajax.js" ScriptMode="Release">
                <Scripts>
                    <asp:ScriptReference Name="WebForms.js" Assembly="System.Web" /><asp:ScriptReference Name="MicrosoftAjax.js" /><asp:ScriptReference Name="MicrosoftAjaxWebForms.js" />
                </Scripts>
            </CompositeScript>
        </asp:ScriptManager>
        <asp:UpdatePanel ID="up" ChildrenAsTriggers="false" runat="server" UpdateMode="conditional" RenderMode="Block" OnPreRender="MakeEditor" class="sm">
        <ContentTemplate>
            <div runat="server" id="divMsg" class="msgarea hide">系统中尚未设置有效的邮件服务器信息！</div>
            <div runat="server" id="sendBox">
				<table class="mbottom_s">
                    <tr><td style="width:3.3em">邮箱：</td><td class="tdInput"><asp:TextBox runat="server" ID="addrs" TextMode="MultiLine" ToolTip="输入收件人邮箱地址，多个地址之间用逗号或分号或换行分隔" Rows="1"></asp:TextBox></td><td class="tdInput right" style="width:6.2em">
                        <asp:UpdatePanel ID="upUsers" runat="server" UpdateMode="conditional" RenderMode="Inline">
                        <ContentTemplate><asp:DropDownList runat="server" ID="ddlUsers" OnSelectedIndexChanged="UpdateUsers"></asp:DropDownList><asp:Button runat="server" ID="btnTrigger" OnClick="UpdateUsers" CssClass="hide" /></ContentTemplate>
                        </asp:UpdatePanel></td></tr>
                    <tr><td>主题：</td><td class="tdInput" colspan="2"><asp:TextBox runat="server" ID="tbSubject" ToolTip="输入邮件主题。双击自动生成" ondblclick="autoSubject();" Rows="1"></asp:TextBox></td></tr>
                </table>
                <asp:TextBox runat="server" ID="ckContent" TextMode="MultiLine"></asp:TextBox>
			</div>
			<div id="btnArea" runat="server">
				<asp:Button runat="server" ID="btnSend" Text="发送" OnClick="SendMail" OnClientClick="return sending();" CssClass="btn big" />
			</div>
            <div runat="server" id="resultArea" class="center" visible="false">
                <div runat="server" id="resultMsg" class="msgarea bigspace mtop_n mbottom_x"></div>
                <input type="button" class="btn big" runat="server" id="btnContinue" value="继续" onserverclick="SendMail" />
                <input type="button" class="btn big" id="btnClose" value="关闭" onclick="back();" />
            </div>
        </ContentTemplate>
        <Triggers>
            <asp:AsyncPostBackTrigger ControlID="btnSend" EventName="Click" />
            <asp:AsyncPostBackTrigger ControlID="btnContinue" EventName="serverclick" />
        </Triggers>
        </asp:UpdatePanel>
        <script src="js/comm.js"></script><script src="js/mail.js"></script>
		</form>
	</body>
</html>