<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<%Links::Config::load_vars%>
<html>

<head>
  <title>Gossamer Links Setup: E-mail Options</title>
  <%include include_style.html%>
</head>

<body>

<%set header_title = 'E-mail Options'%>
<%set header_details = 'These options control how and when e-mails are sent.'%>
<%include include_header.html%>

<form method="post" action="setup.cgi">
<input type="hidden" name="do" value="setup_email" />

<table>
  <tr>
    <th class="heading" colspan="2">E-mail Options:</th>
  </tr>
  <tr>
    <td class="description" colspan="2">
      This should be the e-mail address where all admin notices are sent; it is
      also the Reply-To on any outgoing e-mail notices.
    </td>
  </tr>
  <tr>
    <td class="option">db_admin_email</td>
    <td class="value"><input type="text" name="db_admin_email" value="<%cfg_db_admin_email%>" size="40" /></td>
  </tr>
  <tr>
    <td class="description" colspan="2">
      If you are on a UNIX server, set db_mail_path to the location of
      sendmail.  If using a Windows server, set db_smtp_server to the hostname
      for your SMTP server.  Note: Only one should be set!
    </td>
  </tr>
  <tr>
    <td class="option">db_smtp_server</td>
    <td class="value"><input type="text" name="db_smtp_server" value="<%cfg_db_smtp_server%>" size="40" /></td>
  </tr>
  <tr>
    <td class="option">db_mail_path</td>
    <td class="value"><input type="text" name="db_mail_path" value="<%cfg_db_mail_path%>" size="40" /></td>
  </tr>
  <tr>
    <td class="description" colspan="2">
      Should Gossamer Links automatically send notices to the administrator
      when a user has requested to add or modify a link or review?
    </td>
  </tr>
  <tr>
    <td class="option">admin_email_add</td>
    <td class="value">
      <input type="radio" value="1" name="admin_email_add" id="aea1"<%if cfg_admin_email_add%> checked="checked"<%endif%> /><label for="aea1">Yes</label>
      <input type="radio" value="0" name="admin_email_add" id="aea0"<%ifnot cfg_admin_email_add%> checked="checked"<%endif%> /><label for="aea0">No</label>
    </td>
  </tr>
  <tr>
    <td class="option">admin_email_mod</td>
    <td class="value">
      <input type="radio" value="1" name="admin_email_mod" id="aem1"<%if cfg_admin_email_mod%> checked="checked"<%endif%> /><label for="aem1">Yes</label>
      <input type="radio" value="0" name="admin_email_mod" id="aem0"<%ifnot cfg_admin_email_mod%> checked="checked"<%endif%> /><label for="aem0">No</label>
    </td>
  </tr>
  <tr>
    <td class="option">admin_email_review_add</td>
    <td class="value">
      <input type="radio" value="1" name="admin_email_review_add" id="aera1"<%if cfg_admin_email_review_add%> checked="checked"<%endif%> /><label for="aera1">Yes</label>
      <input type="radio" value="0" name="admin_email_review_add" id="aera0"<%ifnot cfg_admin_email_review_add%> checked="checked"<%endif%> /><label for="aera0">No</label>
    </td>
  </tr>
  <tr>
    <td class="option">admin_email_review_mod</td>
    <td class="value">
      <input type="radio" value="1" name="admin_email_review_mod" id="aerm1"<%if cfg_admin_email_review_mod%> checked="checked"<%endif%> /><label for="aerm1">Yes</label>
      <input type="radio" value="0" name="admin_email_review_mod" id="aerm0"<%ifnot cfg_admin_email_review_mod%> checked="checked"<%endif%> /><label for="aerm0">No</label>
    </td>
  </tr>
  <tr>
    <td class="description" colspan="2">
      Should Gossamer Links notify a user that their link or review addition/modification has
      been validated?
    </td>
  </tr>
  <tr>
    <td class="option">email_add</td>
    <td class="value">
      <input type="radio" value="1" name="email_add" id="ea1"<%if cfg_email_add%> checked="checked"<%endif%> /><label for="ea1">Yes</label>
      <input type="radio" value="0" name="email_add" id="ea0"<%ifnot cfg_email_add%> checked="checked"<%endif%> /><label for="ea0">No</label>
    </td>
  </tr>
  <tr>
    <td class="option">email_mod</td>
    <td class="value">
      <input type="radio" value="1" name="email_mod" id="em1"<%if cfg_email_mod%> checked="checked"<%endif%> /><label for="em1">Yes</label>
      <input type="radio" value="0" name="email_mod" id="em0"<%ifnot cfg_email_mod%> checked="checked"<%endif%> /><label for="em0">No</label>
    </td>
  </tr>
  <tr>
    <td class="option">email_review_add</td>
    <td class="value">
      <input type="radio" value="1" name="email_review_add" id="era1"<%if cfg_email_review_add%> checked="checked"<%endif%> /><label for="era1">Yes</label>
      <input type="radio" value="0" name="email_review_add" id="era0"<%ifnot cfg_email_review_add%> checked="checked"<%endif%> /><label for="era0">No</label>
    </td>
  </tr>
  <tr>
    <td class="description" colspan="2">
      Should Gossamer Links notify a user that their payment has been received and
      their link has been added?
      </td>
  </tr>
  <tr>
    <td class="option">email_payment</td>
    <td class="value">
      <input type="radio" value="1" name="email_payment" id="ep1"<%if cfg_email_payment%> checked="checked"<%endif%> /><label for="ep1">Yes</label>
      <input type="radio" value="0" name="email_payment" id="ep0"<%ifnot cfg_email_payment%> checked="checked"<%endif%> /><label for="ep0">No</label>
    </td>
  </tr>
</table>

<div class="submit">
  <input type="submit" value="Submit Changes" />
  <input type="submit" name="reset_defaults" value="Restore System Defaults" />
</div>

</form>
</body>
</html>
