370d68e668a5329e658c4e0fb0d65ef5.php 8.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131
  1. <?php /*a:3:{s:61:"/data/web/mall.valimart.net/app/admin/view/message/email.html";i:1657785098;s:61:"/data/web/mall.valimart.net/app/admin/view/public/header.html";i:1657785098;s:66:"/data/web/mall.valimart.net/app/admin/view/public/admin_items.html";i:1657785098;}*/ ?>
  2. <!DOCTYPE html>
  3. <html>
  4. <head>
  5. <meta charset="utf-8">
  6. <meta http-equiv="X-UA-Compatible" content="IE=edge">
  7. <title><?php echo htmlentities((isset($html_title) && ($html_title !== '')?$html_title:config('ds_config.site_name'))); ?><?php echo htmlentities(lang('system_backend')); ?></title>
  8. <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
  9. <link rel="stylesheet" href="<?php echo htmlentities(ADMIN_SITE_ROOT); ?>/css/admin.css">
  10. <link rel="stylesheet" href="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/js/jquery-ui/jquery-ui.min.css">
  11. <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/jquery-2.1.4.min.js"></script>
  12. <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/jquery.validate.min.js"></script>
  13. <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/jquery.cookie.js"></script>
  14. <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/common.js"></script>
  15. <script src="<?php echo htmlentities(ADMIN_SITE_ROOT); ?>/js/admin.js"></script>
  16. <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/js/jquery-ui/jquery-ui.min.js"></script>
  17. <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/js/jquery-ui/jquery.ui.datepicker-zh-CN.js"></script>
  18. <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/perfect-scrollbar.min.js"></script>
  19. <script src="<?php echo htmlentities(PLUGINS_SITE_ROOT); ?>/layer/layer.js"></script>
  20. <script type="text/javascript">
  21. var BASESITEROOT = "<?php echo htmlentities(BASE_SITE_ROOT); ?>";
  22. var ADMINSITEROOT = "<?php echo htmlentities(ADMIN_SITE_ROOT); ?>";
  23. var BASESITEURL = "<?php echo htmlentities(BASE_SITE_URL); ?>";
  24. var HOMESITEURL = "<?php echo htmlentities(HOME_SITE_URL); ?>";
  25. var ADMINSITEURL = "<?php echo htmlentities(ADMIN_SITE_URL); ?>";
  26. </script>
  27. </head>
  28. <body>
  29. <div id="append_parent"></div>
  30. <div id="ajaxwaitid"></div>
  31. <div class="page">
  32. <div class="fixed-bar">
  33. <div class="item-title">
  34. <div class="subject">
  35. <h3><?php echo htmlentities(lang('ds_message')); ?></h3>
  36. <h5></h5>
  37. </div>
  38. <?php if($admin_item): ?>
  39. <ul class="tab-base ds-row">
  40. <?php if(is_array($admin_item) || $admin_item instanceof \think\Collection || $admin_item instanceof \think\Paginator): if( count($admin_item)==0 ) : echo "" ;else: foreach($admin_item as $key=>$item): ?>
  41. <li><a href="<?php echo htmlentities($item['url']); ?>" <?php if($item['name'] == $curitem): ?>class="current"<?php endif; ?>><span><?php echo htmlentities($item['text']); ?></span></a></li>
  42. <?php endforeach; endif; else: echo "" ;endif; ?>
  43. </ul>
  44. <?php endif; ?>
  45. </div>
  46. </div>
  47. <form method="post">
  48. <table class="ds-default-table">
  49. <tbody>
  50. <tr class="noborder">
  51. <td class="required w120"><?php echo htmlentities(lang('smtp_server')); ?></td>
  52. <td class="vatop rowform"><input type="text" name="email_host" id="email_host" value="<?php echo htmlentities($list_config['email_host']); ?>" class="w200"/></td>
  53. <td class="vatop tips"><p class="notic"><?php echo htmlentities(lang('set_smtp_server_address')); ?></p></td>
  54. </tr>
  55. <tr class="noborder">
  56. <td class="required w120"><?php echo htmlentities(lang('email_secure')); ?></td>
  57. <td class="vatop rowform">
  58. <select name="email_secure" id="email_secure">
  59. <option value="tls" <?php if($list_config['email_secure'] == 'tls'): ?>selected=selected<?php endif; ?>><?php echo htmlentities(lang('email_secure_tls')); ?></option>
  60. <option value="ssl" <?php if($list_config['email_secure'] == 'ssl'): ?>selected=selected<?php endif; ?>><?php echo htmlentities(lang('email_secure_ssl')); ?></option>
  61. </select>
  62. </td>
  63. <td class="vatop tips"><p class="notic"><?php echo htmlentities(lang('set_email_secure')); ?></p></td>
  64. </tr>
  65. <tr class="noborder">
  66. <td class="required w120"><?php echo htmlentities(lang('email_port')); ?></td>
  67. <td class="vatop rowform"><input type="text" name="email_port" id="email_port" value="<?php echo htmlentities($list_config['email_port']); ?>" class="w200"/></td>
  68. <td class="vatop tips"><p class="notic"><?php echo htmlentities(lang('set_email_port')); ?></p></td>
  69. </tr>
  70. <tr class="noborder">
  71. <td class="required w120"><?php echo htmlentities(lang('sender_mail_address')); ?></td>
  72. <td class="vatop rowform"><input type="text" name="email_addr" id="email_addr" value="<?php echo htmlentities($list_config['email_addr']); ?>" class="w200"/></td>
  73. <td class="vatop tips"><p class="notic"><?php echo htmlentities(lang('if_smtp_authentication')); ?></p></td>
  74. </tr>
  75. <tr class="noborder">
  76. <td class="required w120"><?php echo htmlentities(lang('smtp_user_name')); ?></td>
  77. <td class="vatop rowform"><input type="text" name="email_id" id="email_id" value="<?php echo htmlentities($list_config['email_id']); ?>" class="w200"/></td>
  78. <td class="vatop tips"><p class="notic"><?php echo htmlentities(lang('smtp_user_name_tip')); ?></p></td>
  79. </tr>
  80. <tr class="noborder">
  81. <td class="required w120"><?php echo htmlentities(lang('smtp_user_pwd')); ?></td>
  82. <td class="vatop rowform"><input type="password" name="email_pass" id="email_pass" value="<?php echo htmlentities($list_config['email_pass']); ?>" class="w200"/></td>
  83. <td class="vatop tips"><p class="notic"><?php echo htmlentities(lang('smtp_user_pwd_tip')); ?></p></td>
  84. </tr>
  85. <tr class="noborder">
  86. <td class="required w120"><?php echo htmlentities(lang('test_mail_address')); ?></td>
  87. <td class="vatop rowform">
  88. <input type="text" name="email_test" id="email_test" value="" class="w200"/>
  89. <input type="button" value="<?php echo htmlentities(lang('test_mail')); ?>" name="send_test_email" class="btn btn-small" id="send_test_email" >
  90. </td>
  91. </tr>
  92. </tbody>
  93. <tfoot>
  94. <tr class="tfoot">
  95. <td></td>
  96. <td colspan="15"><input class="btn" type="submit" value="<?php echo htmlentities(lang('ds_submit')); ?>"/></td>
  97. </tr>
  98. </tfoot>
  99. </table>
  100. </form>
  101. </div>
  102. <script>
  103. $(document).ready(function(){
  104. $('#send_test_email').click(function(){
  105. $.ajax({
  106. type:'POST',
  107. url:"<?php echo url('Message/email_testing'); ?>",
  108. data:{'email_host':$('#email_host').val(),'email_secure':$('#email_secure option:selected').val(),'email_port':$('#email_port').val(),'email_addr':$('#email_addr').val(),'email_id':$('#email_id').val(),'email_pass':$('#email_pass').val(),'email_test':$('#email_test').val()},
  109. error:function(html){
  110. layer.alert(html.msg);
  111. },
  112. success:function(html){
  113. layer.alert(html.msg);
  114. },
  115. dataType:'json'
  116. });
  117. });
  118. });
  119. </script>