member_group_add.tpl.php 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138
  1. <?php defined('IN_ADMIN') or exit('No permission resources.');?>
  2. <?php include $this->admin_tpl('header', 'admin');?>
  3. <script language="javascript" type="text/javascript" src="<?php echo JS_PATH?>formvalidator.js" charset="UTF-8"></script>
  4. <script language="javascript" type="text/javascript" src="<?php echo JS_PATH?>formvalidatorregex.js" charset="UTF-8"></script>
  5. <script type="text/javascript">
  6. <!--
  7. $(function(){
  8. $.formValidator.initConfig({autotip:true,formid:"myform",onerror:function(msg){}});
  9. $("#name").formValidator({onshow:"<?php echo L('input').L('groupname')?>",onfocus:"<?php echo L('groupname').L('between_2_to_8')?>"}).inputValidator({min:2,max:15,onerror:"<?php echo L('groupname').L('between_2_to_8')?>"}).regexValidator({regexp:"ps_username",datatype:"enum",onerror:"<?php echo L('groupname').L('format_incorrect')?>"}).ajaxValidator({
  10. type : "get",
  11. url : "",
  12. data :"m=member&c=member_group&a=public_checkname_ajax",
  13. datatype : "html",
  14. async:'false',
  15. success : function(data){
  16. if( data == "1" ) {
  17. return true;
  18. } else {
  19. return false;
  20. }
  21. },
  22. buttons: $("#dosubmit"),
  23. onerror : "<?php echo L('groupname_already_exist')?>",
  24. onwait : "<?php echo L('connecting_please_wait')?>"
  25. });
  26. $("#group_point").formValidator({tipid:"pointtip",onshow:"<?php echo L('input').L('point')?>",onfocus:"<?php echo L('point').L('between_1_to_8_num')?>"}).regexValidator({regexp:"^\\d{1,8}$",onerror:"<?php echo L('point').L('between_1_to_8_num')?>"});
  27. $("#group_starnum").formValidator({tipid:"starnumtip",onshow:"<?php echo L('input').L('starnum')?>",onfocus:"<?php echo L('starnum').L('between_1_to_8_num')?>"}).regexValidator({regexp:"^\\d{1,8}$",onerror:"<?php echo L('starnum').L('between_1_to_8_num')?>"});
  28. $("#maxmessagenum").formValidator({tipid:"maxmessagenumtip",onshow:"<?php echo L('input').L('maxmessagenum')?>",onfocus:"<?php echo L('maxmessagenum').L('between_1_to_8_num')?>"}).regexValidator({regexp:"^\\d{1,8}$",onerror:"<?php echo L('maxmessagenum').L('between_1_to_8_num')?>"});
  29. $("#allowpostnum").formValidator({tipid:"allowpostnumip",onshow:"<?php echo L('input').L('allowpostnum')?>",onfocus:"<?php echo L('allowpostnum').L('between_1_to_8_num')?>"}).regexValidator({regexp:"^\\d{1,8}$",onerror:"<?php echo L('allowpostnum').L('between_1_to_8_num')?>"});
  30. });
  31. //-->
  32. </script>
  33. <div class="pad-10">
  34. <div class="common-form">
  35. <form name="myform" action="?m=member&c=member_group&a=add" method="post" id="myform">
  36. <fieldset>
  37. <legend><?php echo L('basic_configuration')?></legend>
  38. <table width="100%" class="table_form">
  39. <tr>
  40. <td width="120"><?php echo L('member_group_name')?></td>
  41. <td><input type="text" name="info[name]" class="input-text" id="name"></td>
  42. </tr>
  43. <tr>
  44. <td><?php echo L('member_group_creditrange')?></td>
  45. <td>
  46. <input type="text" name="info[point]" class="input-text" id="group_point" value="" size="6"></td>
  47. </tr>
  48. <tr>
  49. <td><?php echo L('member_group_starnum')?></td>
  50. <td><input type="text" name="info[starnum]" class="input-text" id="group_starnum" size="6"></td>
  51. </tr>
  52. </table>
  53. </fieldset>
  54. <div class="bk15"></div>
  55. <fieldset>
  56. <legend><?php echo L('more_configuration')?></legend>
  57. <table width="100%" class="table_form">
  58. <tr>
  59. <td><?php echo L('member_group_permission')?></td>
  60. <td>
  61. <span class="ik lf" style="width:120px;">
  62. <input type="checkbox" name="info[allowpost]">
  63. <?php echo L('member_group_publish')?>
  64. </span>
  65. <span class="ik lf" style="width:120px;">
  66. <input type="checkbox" name="info[allowpostverify]">
  67. <?php echo L('member_group_publish_verify')?>
  68. </span>
  69. <span class="ik lf" style="width:120px;">
  70. <input type="checkbox" name="info[allowupgrade]">
  71. <?php echo L('member_group_upgrade')?>
  72. </span>
  73. <span class="ik lf" style="width:120px;">
  74. <input type="checkbox" name="info[allowsendmessage]">
  75. <?php echo L('member_group_sendmessage')?>
  76. </span>
  77. <?php
  78. if($groupinfo['groupid']!=8) {?>
  79. <span class="ik lf" style="width:120px;">
  80. <input type="checkbox" name="info[allowattachment]">
  81. <?php echo L('allowattachment')?>
  82. </span>
  83. <?php }?>
  84. <span class="ik lf" style="width:120px;">
  85. <input type="checkbox" name="info[allowsearch]">
  86. <?php echo L('allowsearch')?>
  87. </span>
  88. </td>
  89. </tr>
  90. <tr>
  91. <td width="80"><?php echo L('member_group_upgradeprice')?></td>
  92. <td>
  93. <span class="ik lf" style="width:120px;">
  94. <?php echo L('member_group_dayprice')?>:
  95. <input type="text" name="info[price_d]" class="input-text" size="6">
  96. </span>
  97. <span class="ik lf" style="width:120px;">
  98. <?php echo L('member_group_monthprice')?>:
  99. <input type="text" name="info[price_m]" class="input-text" size="6">
  100. </span>
  101. <span class="ik lf" style="width:120px;">
  102. <?php echo L('member_group_yearprice')?>:
  103. <input type="text" name="info[price_y]" class="input-text" size="6">
  104. </span>
  105. </td>
  106. </tr>
  107. <tr>
  108. <td width="80"><?php echo L('member_group_maxmessagenum')?></td>
  109. <td><input type="text" name="info[allowmessage]" class="input-text" id="allowmessage" size="8"></td>
  110. </tr>
  111. <tr>
  112. <td width="80"><?php echo L('allowpostnum')?></td>
  113. <td><input type="text" name="info[allowpostnum]" class="input-text" id="allowpostnum" size="8"> <?php echo L('zero_nolimit')?></td>
  114. </tr>
  115. <tr>
  116. <td width="80"><?php echo L('member_group_username_color')?></td>
  117. <td><input type="text" name="info[usernamecolor]" class="input-text" id="usernamecolor" size="8" value="#000000"></td>
  118. </tr>
  119. <tr>
  120. <td width="80"><?php echo L('member_group_icon')?></td>
  121. <td><input type="text" name="info[icon]" class="input-text" id="icon" value="images/group/vip.jpg" size="40"></td>
  122. </tr>
  123. <tr>
  124. <td width="80"><?php echo L('member_group_description')?></td>
  125. <td><input type="text" name="info[description]" class="input-text" size="60"></td>
  126. </tr>
  127. </table>
  128. </fieldset>
  129. <div class="bk15"></div>
  130. <input name="dosubmit" type="submit" id="dosubmit" value="<?php echo L('submit')?>" class="dialog">
  131. </form>
  132. </div>
  133. </div>
  134. </body>
  135. </html>