<?php

include("../includes/site_config.php");
include('../session_handler.inc');
include_once __INCLUDE_CLASS_PATH."/class.ItemManager.php";
$option_manager = new OptionManager();
$mail=$option_manager->GetValue('mail');
$Sess_UserType=$_SESSION['Sess_UserType'];


if ($Sess_UserType != "A") {
    exit;
}
# retrieve the template
$area = 'member';

$sd="OFF";
//if(file_exists($CONST_INCLUDE_ROOT."/speeddating/index.php")) $sd="ON";
?>
<?php include("include/header.php"); ?>
<div class="admin-mainwidth">
<div class="admin-page-header"><div class="admin-page-heading">&nbsp;&nbsp;Send Mass Email</div></div>
<div class="clear"></div>
<div class="admin-page">
  <table width="<?php print("$CONST_TABLE_WIDTH"); ?>" align="<?php print("$CONST_TABLE_ALIGN"); ?>" border="0" cellspacing="<?php print("$CONST_TABLE_CELLSPACING"); ?>" cellpadding="<?php print("$CONST_TABLE_CELLPADDING"); ?>">
    <tr>
      <td align="right">
      <?php 	  //require_once("$CONST_INCLUDE_ROOT/user_status.inc.php");	  require_once("../user_status.inc.php");	  ?>
      </td>
    </tr>
    <tr><td>

    <table width="100%"  border="0" cellspacing="<?php print("$CONST_SUBTABLE_CELLSPACING"); ?>" cellpadding="<?php print("$CONST_SUBTABLE_CELLPADDING"); ?>">
        <form method='post' action='<?php echo $CONST_LINK_ROOT?>/admin/admin_sendmail.php<?php print("?PHPSESSID=".session_id()); ?>' name="mailForm">
          <tr class="normal">
            <!--<td align="left"><?php echo ADMINMAIL_EMAILTO?></td>
            <td align="left">
              <input type="text" class="input" name="txtAddress" size="36" tabindex="1" onKeyDown="admin_mail('txtAddress','<?php echo $sd ?>');" onKeyUp="admin_mail('txtAddress','<?php echo $sd ?>');">
              (<?php echo ADMINMAIL_SEND?>) </td>-->
          </tr>
          <tr class="normal">
            <td align="left"><?=REGISTER_NEWSLETER?></td>
            <td align="left"><input type="checkbox" name="newsletter" value="ON" /></td>
          </tr>
          <tr class="normal">
            <td align="left"><?php echo ADMINMAIL_ALL?></td>
            <td align="left">
              <input type="checkbox" name="chkAllusers" value="ON" onClick="admin_mail('chkAllusers','<?php echo $sd ?>');"></td>
          </tr>
         <!-- <tr class="normal">
            <td align="left"><?php echo ADM_AFFILIATES ?></td>
            <td align="left"><input type="checkbox" name="chkAffiliates" value="ON" onClick="admin_mail('chkAffiliates','<?php echo $sd ?>');"> (<?php echo ADMINMAIL_TICK5?>)</td>
          </tr>-->
          <tr class="normal">
            <!--<td align="left"><?php echo ADMINMAIL_FROMFILE?></td>
            <td align="left">
              <input type="checkbox" name="chkFile" value="ON" onClick="admin_mail('chkFile','<?php echo $sd ?>');">
              (<?php echo ADMINMAIL_TICK2?>)</td>
          </tr>
<?php /*?><?php if(file_exists($CONST_INCLUDE_ROOT."/speeddating/index.php")) { ?>
          <tr class="normal">
            <td align="left"><?php echo ADM_SPEEDDATING ?></td>
            <td align="left">
              <input type="checkbox" name="chkSpeeddating" value="ON" onClick="admin_mail('chkSpeeddating','<?php echo $sd ?>');">
              (<?php echo ADMINMAIL_SPEEDDATING?>)</td>
          </tr>
<?php } ?><?php */?>
          <tr class="normal">
            <td align="left"><?php echo ADMINMAIL_INTR?></td>
            <td align="left">
              <input type="checkbox" name="chkIntro" value="ON">
              (<?php echo ADMINMAIL_TICK3?>)</td>
          </tr>
          <tr class="normal">
            <td align="left"><?php echo ADMINMAIL_HTML?></td>
            <td align="left">
              <input type="checkbox" name="chkType" value="ON">
              (<?php echo ADMINMAIL_TICK4?>) </td>-->
          </tr>
          <tr class="normal">
            <td align="left"><?php echo SEX?></td>
            <td align="left">
              <select name="lstGender" size="1" class="inputs">
                <option selected value="A"><?php echo GENERAL_ALL?></option>
                <option value="M"><?php echo SEX_MALE?></option>
                <option value="F"><?php echo SEX_FEMALE?></option>
              </select></td>
          </tr>
          <tr class="normal">
            <td align="left"><?php echo STATUS?> </td>
            <td align="left">
              <select class="input" name="lstStatus">
                <option value="All"><?php echo STATUS_A?></option>
                <option value="Standard"><?php echo STATUS_S?></option>
                <option value="Premium"><?php echo STATUS_P?></option>
                <option value="Inactive"><?php echo STATUS_I?></option>
				<option value="Rejected"><?php echo STATUS_REJECTED ?></option>
              </select> </td>
          </tr>
          <tr class="normal">
            <td align="left"><?php echo ADMINMAIL_SEND_TYPE?></td>
            <td align="left">
              <select size="1" name="lstSendType" class="input">
                <option selected value="outside"><?php echo ADMINMAIL_OUT?></option>
                <option value="inside_hidden"><?php echo ADMINMAIL_INS?></option>
              </select></td>
          </tr>
          <tr class="normal">
            <td align="left"><?php echo ADMINMAIL_SUB?></td>
            <td align="left" valign="top">
              <input type="text" class="input" name="txtSubject" size="50" tabindex="2">            </td>
          </tr>
          <tr class="normal">
            <td align="left" valign="top"><?php echo ADMINMAIL_MESS?></td>
            <td align="left" valign="top">
              <textarea  class="inputl"rows="10" name="txtMessage" cols="64" tabindex="2"></textarea></td>
          </tr>
          <tr class="normal">
            <td align="left"><?php echo ADMINMAIL_FROM?></td>
            <td align="left">
              <input type="text" class="inputl" name="txtReply" size="33" tabindex="7" value="<?php print("$mail"); ?>">            </td>
          </tr>
          <tr align="center">
            <td colspan="2" class="tdfoot">
              <input type="button" name="Button" value="<?php echo BUTTON_BACK ?>" class="normal" OnClick="javascript:history.go(-1);">
              <input type="submit" name="Submit2" value="<?php echo BUTTON_SEND ?>" class="normal"></td>
          </tr>
        </form>
      </table></td>
    </tr>
</table></div><div class="admin-page-bottom"></div></div>
<?php include("include/footer.php"); ?>
