complain_subject_add.html 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. {include file="public/header" /}
  2. <div class="page">
  3. <div class="fixed-bar">
  4. <div class="item-title">
  5. <div class="subject">
  6. <h3>{$Think.lang.ds_complain}</h3>
  7. <h5></h5>
  8. </div>
  9. {include file="public/admin_items" /}
  10. </div>
  11. </div>
  12. <form id="add_form" method="post" enctype="multipart/form-data">
  13. <table class="ds-default-table">
  14. <tbody>
  15. <tr>
  16. <td colspan="2" class="required"><label class="validation" for="complain_subject_content">{$Think.lang.complain_subject_content}:</label></td>
  17. </tr>
  18. <tr class="noborder">
  19. <td class="vatop rowform"><input type="text" id="complain_subject_content" name="complain_subject_content" class="txt"></td>
  20. <td class="vatop tips"></td>
  21. </tr>
  22. <tr>
  23. <td colspan="2" class="required"><label class="validation" for="complain_subject_desc">{$Think.lang.complain_subject_desc}:</label></td>
  24. </tr>
  25. <tr class="noborder">
  26. <td class="vatop rowform"><textarea name="complain_subject_desc" rows="6" class="tarea" id="complain_subject_desc"></textarea></td>
  27. <td class="vatop tips"></td>
  28. </tr>
  29. </tbody>
  30. <tfoot>
  31. <tr class="tfoot">
  32. <td colspan="15" ><input class="btn" type="submit" value="{$Think.lang.ds_submit}"/></td>
  33. </tr>
  34. </tfoot>
  35. </table>
  36. </form>
  37. </div>
  38. <script type="text/javascript">
  39. $(document).ready(function(){
  40. //页面输入内容验证
  41. $("#add_form").validate({
  42. errorPlacement: function(error, element){
  43. error.appendTo(element.parent().parent().prev().find('td:first'));
  44. },
  45. rules : {
  46. complain_subject_content: {
  47. required : true,
  48. maxlength : 50
  49. },
  50. complain_subject_desc: {
  51. required : true,
  52. maxlength : 100
  53. }
  54. },
  55. messages : {
  56. complain_subject_content: {
  57. required : '{$Think.lang.complain_subject_content_error}',
  58. maxlength : '{$Think.lang.complain_subject_content_error}'
  59. },
  60. complain_subject_desc: {
  61. required : '{$Think.lang.complain_subject_desc_error}',
  62. maxlength : '{$Think.lang.complain_subject_desc_error}'
  63. }
  64. }
  65. });
  66. });
  67. </script>