edit_mail_acc.html 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231
  1. <div class="l-center edit">
  2. <div class="l-sort clearfix">
  3. <div class="l-unit-toolbar__buttonstrip">
  4. <a class="ui-button cancel" id="btn-back" href="/list/mail/?domain=<?=htmlentities(trim($v_domain, "'"))?>&token=<?=$_SESSION['token']?>"><i class="fas fa-arrow-left status-icon blue"></i> <?=_('Back')?></a>
  5. </div>
  6. <div class="l-unit-toolbar__buttonstrip float-right">
  7. <a href="#" class="ui-button" data-action="submit" data-id="vstobjects"><i class="fas fa-save status-icon purple"></i> <?=_('Save')?></a>
  8. </div>
  9. </div>
  10. </div>
  11. <div class="l-separator"></div>
  12. <div class="l-center animated fadeIn">
  13. <?php
  14. $back = $_SESSION['back'];
  15. if (empty($back)) {
  16. $back = "location.href='/list/mail/?domain=".$_GET['domain']."'";
  17. } else {
  18. $back = "location.href='".$back."'";
  19. }
  20. ?>
  21. <form id="vstobjects" name="v_edit_mail_acc" method="post" class="<?=$v_status?>">
  22. <input type="hidden" name="token" value="<?=$_SESSION['token']?>" />
  23. <input type="hidden" name="save" value="save" />
  24. <table class='data'>
  25. <tr class="data-add">
  26. <td class="data-dotted">
  27. <table class="data-col1">
  28. <tr>
  29. <td>
  30. </td>
  31. </tr>
  32. </table>
  33. </td>
  34. <td class="data-dotted">
  35. <table class="data-col2" width="440px">
  36. <tr>
  37. <td class="step-top">
  38. <span class="page-title"><?=_('Editing Mail Account')?></span>
  39. </td>
  40. </tr>
  41. <tr>
  42. <td>
  43. <?php
  44. if (!empty($_SESSION['error_msg'])) {
  45. echo "<span class=\"vst-error\"> <i class=\"fas fa-exclamation-circle status-icon red\"></i> ".htmlentities($_SESSION['error_msg'])."</span>";
  46. } else {
  47. if (!empty($_SESSION['ok_msg'])) {
  48. echo "<span class=\"vst-ok\"> <i class=\"fas fa-check-circle status-icon green\"></i> ".$_SESSION['ok_msg']."</span>";
  49. }
  50. }
  51. ?>
  52. </td>
  53. </tr>
  54. <tr>
  55. <td class="vst-text step-top input-label">
  56. <?php print _('Account');?>
  57. </td>
  58. </tr>
  59. <tr>
  60. <td>
  61. <input type="text" size="20" class="vst-input" name="v_email" value="<?=htmlentities($_GET['account'])."@".htmlentities($_GET['domain'])?>" disabled >
  62. <input type="hidden" name="v_domain" value="<?=htmlentities(trim($v_domain, "'"))?>">
  63. <input type="hidden" name="v_account" value="<?=htmlentities(trim($v_account, "'"))?>">
  64. </td>
  65. </tr>
  66. <tr>
  67. <td class="vst-text input-type input-label">
  68. <?php print _('Password');?> / <a href="javascript:randomString();" class="generate"><?=_('generate')?></a>
  69. </td>
  70. </tr>
  71. <tr>
  72. <td>
  73. <input type="text" size="20" class="vst-input password" name="v_password" value="<?=htmlentities(trim($v_password, "'"))?>"><br />
  74. <meter max="4" id="meter"></meter>
  75. </td>
  76. </tr>
  77. <tr>
  78. <td class="vst-text">
  79. <?php print _('Your password must have at least');?>
  80. <ul>
  81. <li><?php print _('8 characters long');?></li>
  82. <li><?php print _('1 uppercase & 1 lowercase character');?></li>
  83. <li><?php print _('1 number');?></li>
  84. </ul>
  85. </td>
  86. </tr>
  87. <tr>
  88. <td class="vst-text input-type input-label">
  89. <?php print _('Quota');?> <span class="optional">(<?=_('in megabytes')?>)</span>
  90. </td>
  91. </tr>
  92. <tr>
  93. <td>
  94. <input type="text" size="20" class="vst-input" name="v_quota" value="<? if (!empty($v_quota)) {echo htmlentities(trim($v_quota, "'"));} else { echo "0"; } ?>">
  95. <i class="unlim-trigger fas fa-infinity" id="unlim-quota"></i>
  96. </td>
  97. </tr>
  98. <tr>
  99. <td class="vst-text input-type input-label">
  100. <?php print _('Aliases');?> <span class="optional">(<?=_('use local-part')?>)</span>
  101. </td>
  102. </tr>
  103. <tr>
  104. <td>
  105. <textarea size="20" class="vst-textinput short" name="v_aliases"><?=htmlentities(trim($v_aliases, "'"))?></textarea>
  106. </td>
  107. </tr>
  108. <tr>
  109. <td class="vst-text input-type input-label">
  110. <?php print _('Forward to');?> <span class="optional">(<?=_('one or more email addresses')?>)</span>
  111. </td>
  112. </tr>
  113. <tr>
  114. <td>
  115. <textarea size="20" class="vst-textinput short" name="v_fwd" id="v_fwd" <?php if($v_blackhole == 'yes') echo "disabled";?>><?=htmlentities(trim($v_fwd, "'"))?></textarea>
  116. </td>
  117. </tr>
  118. <tr>
  119. <td class="vst-text input-label">
  120. <label><input type="checkbox" size="20" class="vst-checkbox" id="v_blackhole" name="v_blackhole" <?php if ($v_blackhole == 'yes') echo "checked=yes" ?>> <?php print _('Discard all mail');?></label>
  121. </td>
  122. </tr>
  123. <tr <?php if ($v_blackhole == 'yes') echo 'style="display:none"'; ?> id="id_fwd_for">
  124. <td class="vst-text input-type input-label">
  125. <label><input type="checkbox" size="20" class="vst-checkbox" id="v_fwd_for" name="v_fwd_only" <?php if ($v_fwd_only == 'yes') echo "checked=yes" ?>> <?php print _('Do not store forwarded mail');?></label>
  126. </td>
  127. </tr>
  128. <tr>
  129. <td class="vst-text input-type input-label">
  130. <label><input type="checkbox" size="20" class="vst-checkbox" name="v_autoreply" <?php if ($v_autoreply == 'yes') echo "checked=yes" ?> onclick="javascript:elementHideShow('autoreplytable');"> <?php print _('Autoreply');?></label>
  131. </td>
  132. </tr>
  133. <tr>
  134. <td>
  135. <table style="display:<?php if ($v_autoreply == 'yes') { echo 'block';} else {echo 'none';}?> ;" id="autoreplytable">
  136. <tr>
  137. <td class="vst-text" style="padding: 12px 0 0 0;">
  138. <?php print _('Message');?>
  139. </td>
  140. </tr>
  141. <tr>
  142. <td>
  143. <textarea size="20" class="vst-textinput short" name="v_autoreply_message"><?=htmlentities(trim($v_autoreply_message, "'"))?></textarea>
  144. </td>
  145. </tr>
  146. </table>
  147. </td>
  148. </tr>
  149. <tr>
  150. <td class="vst-text input-label">
  151. <?php print _('Send login credentials to email address') ?>
  152. </td>
  153. </tr>
  154. <tr>
  155. <td>
  156. <input type="text" class="vst-input" name="v_send_email" value="<?=htmlentities(trim($v_send_email, "'"))?>">
  157. <input type="hidden" name="v_credentials" id="v_credentials">
  158. </td>
  159. </tr>
  160. </table>
  161. <table class="data-col2">
  162. </table>
  163. </td>
  164. <td class="mail-infoblock-td">
  165. <div class="mail-infoblock">
  166. <table>
  167. <?php $uname_arr=posix_uname(); $hostname=$uname_arr['nodename']; ?>
  168. <tr>
  169. <td colspan="2">
  170. <select id="mail_configuration" class="vst-list flat">
  171. <option v_type="hostname" domain="<?=$v_domain?>"><?=_('Use domain hostname')?></option>
  172. <option v_type="starttls"><?=_('Use STARTTLS')?></option>
  173. <option v_type="ssl"><?=_('Use SSL / TLS')?></option>
  174. <option v_type="no_encryption" domain="<?=htmlentities(trim($v_domain, "'"))?>" no_encryption="<?=_('No encryption')?>"><?=_('No encryption')?></option>
  175. </select>
  176. </td>
  177. </tr>
  178. <tr>
  179. <td><?=_('Username')?>:</td>
  180. <td><div><span id="v_account">example</span>@<?=htmlentities(trim($v_domain, "'"))?></div></td>
  181. </tr>
  182. <tr>
  183. <td><?=_('Password')?>:</td>
  184. <td><div id="v_password">******</div></td>
  185. </tr>
  186. <tr>
  187. <td><?=_('IMAP hostname')?>:</td>
  188. <td><div id="td_imap_hostname">mail.<?=$v_domain?></div></td>
  189. </tr>
  190. <tr>
  191. <td><?=_('IMAP port')?>:</td>
  192. <td><div id="td_imap_port">143</div></td>
  193. </tr>
  194. <tr>
  195. <td><?=_('IMAP security')?>:</td>
  196. <td><div id="td_imap_encryption"><?=_('STARTTLS')?></div></td>
  197. </tr>
  198. <tr>
  199. <td><?=_('IMAP auth method')?>:</td>
  200. <td><div><?=_('Normal password')?></div></td>
  201. </tr>
  202. <tr>
  203. <td><?=_('SMTP hostname')?>:</td>
  204. <td><div id="td_smtp_hostname">mail.<?=$v_domain?></div></td>
  205. </tr>
  206. <tr>
  207. <td><?=_('SMTP port')?>:</td>
  208. <td><div id="td_smtp_port">587</div></td>
  209. </tr>
  210. <tr>
  211. <td><?=_('SMTP security')?>:</td>
  212. <td><div id="td_smtp_encryption"><?=_('STARTTLS')?></div></td>
  213. </tr>
  214. <tr>
  215. <td><?=_('SMTP auth method')?>:</td>
  216. <td><div><?=_('Normal password')?></div></td>
  217. </tr>
  218. <tr>
  219. <td><?=_('Webmail URL')?>:</td>
  220. <td><div><a class="vst" href="http://<?=$v_webmail_alias?>" target="_blank">http://<?=$v_webmail_alias?> <i></i></a></div></td>
  221. </tr>
  222. </table>
  223. </div>
  224. </td>
  225. </tr>
  226. </table>
  227. </form>
  228. </div>