<%@ 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,user-scalable=0">
</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>
                    <tr id="trInput"><td><asp:TextBox runat="server" ID="addrs" CssClass="nobgborder" placeholder="邮箱地址" TextMode="MultiLine" ToolTip="输入收件人邮箱，以逗号或分号或换行分隔" Rows="1"></asp:TextBox></td><td class="right vtop" 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 colspan="2"><asp:TextBox runat="server" ID="tbSubject" CssClass="bold" placeholder="主题" 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="Ckeditor/ckeditor.js"></script>
        <script src="Ckeditor/Ckfinder/ckfinder.js"></script>
        <script src="js/mail.js"></script>
		</form>
	</body>
</html>