  <% 
	data_path="../../" 'ACC连接数据库路径，对SQL无效
	numid="19"
	dir="../err.asp" 
  %>
  <!--#include file="../../conn/conn.asp"-->
  <!--#include file="../../inc/safe.asp"-->
 <!--#include file="../rolecheck.asp"-->
<script language="JavaScript" type="text/JavaScript">
<!--
function lanier(theURL,winName,features) { 
  window.open(theURL,winName,features);
}
//-->
</script>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>EMAIL群发</title>
<LINK href="../css/style.css" rel=stylesheet type=text/css>
<script language="javascript">
function selectall(){
	for(i=0;i!=document.email.elements.length;i++){
		document.email.elements[i].checked=!document.email.elements[i].checked;
	}
}
</script>
<style type="text/css">
<!--
body {
	margin-left: 2px;
	margin-top: 0px;
	margin-right: 0px;
	margin-bottom: 0px;
}
.STYLE1 {
	color: #993300;
	font-size: 13px;
}
.STYLE2 {
	font-size: 14px;
	font-weight: bold;
}
.tdover{background:#C3CDDE;}
.tdout{background:#FFFFFF;}
-->
</style></head>
<%
tit=request("tit")
con=request("con")
tid=request("id")
mail_pwd=request("mailpwd")
frommail=request("frommail")
mail_smtp=request("mailsmtp")
set rs=server.CreateObject("adodb.recordset")
sqlcom="select * from yixiang_corporation where gradeid="&tid&""
rs.open sqlcom,conn,1,1
msg_per_page=15
if rs.eof then
  response.Write("<script language='javascript'>alert('该等级下暂无会员！');history.go(-1);</script>")
  response.end
end if
%>
<!--#include file="../../inc/headpage.asp"-->
<body>
<form  name="email" method="post" action="Bs_Mail_Send.asp">
  <table width="100%" style="border:1px solid #A3B2CC;" align="center" cellpadding="0" cellspacing="0" class="border">
    <tr>
      <td height="25" colspan="5" align="center" class="topbg"><span class="STYLE2">=&gt;短信群发&lt;=</span></td>
    </tr>
    <tr class="Title">
      <td width="8%" height="22" align="center" style="border:1px solid #A3B2CC; border-left:none;">选 择</td>
      <td width="21%" align="center" style="border:1px solid #A3B2CC; border-left:none;">用户名</td>
      <td width="31%" align="center" style="border:1px solid #A3B2CC; border-left:none;">公司名称</td>
      <td width="20%" align="center" style="border:1px solid #A3B2CC; border-left:none;">邮 箱</td>
      <td width="20%" align="center" style="border:1px solid #A3B2CC; border-left:none;">真实姓名</td>
    </tr>
	<input type="hidden" name="mailsubject" id="mailsubject" value=<%=tit%>>
	<input type="hidden" name="mailbody" id="mailbody" value=<%=con%>>
	<input type="hidden" name="frommail" id="frommail" value=<%=frommail%>>
	<input type="hidden" name="mail_smtp" id="mail_smtp" value=<%=mail_smtp%>>
	<input type="hidden" name="mail_pwd" id="mail_pwd" value=<%=mail_pwd%>>
    <%do while not rs.eof%>
    <tr onMouseOver="this.className='tdover'" onMouseOut="this.className='tdout'">
      <td height="23" align="center" style="border:1px solid #A3B2CC; border-top:none; border-left:none;"><input name="tomail" type="checkbox" id="tomail" value="<%=rs("email")%>" /></td>
      <td align="center" style="border:1px solid #A3B2CC; border-top:none; border-left:none;"><%=rs("user")%></td>
      <td align="center" style="border:1px solid #A3B2CC; border-top:none; border-left:none;"><%=rs("qymc")%></td>
      <td align="center" style="border:1px solid #A3B2CC; border-top:none; border-left:none;"><%=rs("email")%></td>
      <td align="center" style="border:1px solid #A3B2CC; border-top:none; border-left:none;"><%=rs("name")%></td>
    </tr>
    <%
	 rs.movenext
	 loop
	' rs.close
'	 set rs=nothing
	%>
    <tr>
      <td height="22" colspan="5" class="tdbg2"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
        <tr>
          <td style="border:1px solid #A3B2CC; border-top:none;"><input type="button" name="Submit" value="全选" onClick="selectall()">
            <input type="reset" name="Submit2" value="取消">
            <input type="submit" name="Submit3" value="确定发送">&nbsp;&nbsp;<span class="STYLE1">⑴每次发送邮件请不要设置过多，要根据服务器的情况而定！⑵尽量在访问量小的时候操作!
		    </span></td> 
		         
        </tr>
		<td width="76%" align="center" style="border:1px solid #A3B2CC; border-top:none; border-bottom:none;"><%=listPages("Member_sendmail.asp?tit="&tit&"&con="&con&"&id="&tid&"&mailpwd="&mail_pwd&"&frommail="&frommail&"&mailsmtp="&mail_smtp&"")%></td>
		<tr>
		</tr>
      </table></td>
    </tr>
  </table>
</form>
<br>
</body>
</html>
