You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

95 lines
3.6 KiB

7 years ago
7 years ago
7 years ago
7 years ago
7 years ago
7 years ago
7 years ago
7 years ago
7 years ago
7 years ago
  1. <div class="ax-button-group">
  2. <div class="left">
  3. <h2><?=$board['brd_title']?> 글쓰기</h2>
  4. </div>
  5. </div>
  6. <?=$form_open?>
  7. <?=validation_errors('<p class="alert alert-danger">')?>
  8. <div data-ax-tbl>
  9. <?php if($use_category) :?>
  10. <div data-ax-tr>
  11. <div data-ax-td>
  12. <div data-ax-td-label>카테고리</div>
  13. <div data-ax-td-wrap>
  14. <select class="form-control" name="post_category">
  15. <?php foreach($board['category'] as $cate):?>
  16. <option value="<?=$cate?>" <?=$cate==element('post_category', $view)?'selected':''?>><?=$cate?></option>
  17. <?php endforeach;?>
  18. </select>
  19. </div>
  20. </div>
  21. </div>
  22. <?php endif;?>
  23. <div data-ax-tr>
  24. <div data-ax-td class="width-100">
  25. <div data-ax-td-label>제목</div>
  26. <div data-ax-td-wrap>
  27. <input class="form-control" id="w_title" name="post_title" value="<?=element('post_title', $view)?>" required>
  28. </div>
  29. </div>
  30. </div>
  31. <?php if(! defined('IS_REPLY_WRITE_FORM') && $use_notice) :?>
  32. <div data-ax-tr>
  33. <div data-ax-td class="width-100">
  34. <div data-ax-td-label>공지</div>
  35. <div data-ax-td-wrap>
  36. <label class="w-check">
  37. <input type="checkbox" value="Y" name="post_notice" <?=element('post_notice',$view,'N')=='Y'?'checked':''?>><span>공지로 등록</span>
  38. </label>
  39. </div>
  40. </div>
  41. </div>
  42. <?php endif;?>
  43. <div data-ax-tr>
  44. <div data-ax-td class="width-100">
  45. <div data-ax-td-label>내용</div>
  46. <div data-ax-td-wrap>
  47. <?=get_editor('post_content', element('post_content', $view), '');?>
  48. </div>
  49. </div>
  50. </div>
  51. <div data-ax-tr>
  52. <div data-ax-td class="width-100">
  53. <div data-ax-td-label>태그</div>
  54. <div data-ax-td-wrap>
  55. <input class="form-control" id="w_keywords" name="post_keywords" value="<?=element('post_keywords', $view)?>">
  56. </div>
  57. </div>
  58. </div>
  59. <div data-ax-tr>
  60. <div data-ax-td class="width-100">
  61. <div data-ax-td-label>파일첨부</div>
  62. <div data-ax-td-wrap>
  63. [widget name="board_file_upload"]
  64. </div>
  65. </div>
  66. </div>
  67. <?php if( $post_idx && count(element('file', $view, array())) > 0) :?>
  68. <div data-ax-tr>
  69. <div data-ax-td class="width-100">
  70. <div data-ax-td-label>첨부된 파일</div>
  71. <div data-ax-td-wrap>
  72. <?php foreach($view['file'] as $attach) : ?>
  73. <div class="col-sm-3">
  74. <?php $img_url = ($attach['att_is_image'] == 'Y') ? base_url($attach['att_filepath']) : base_url('assets/images/common/attach.png'); ?>
  75. <figure>
  76. <img class="img-responsive" src="<?=$img_url?>" <?=($attach['att_is_image'] != 'Y')?'style="max-width:64px;margin:auto"':''?>>
  77. <figcaption><?=$attach['att_origin']?></figcaption>
  78. </figure>
  79. <div class="checkbox">
  80. <label><input type="checkbox" name="del_file[]" value="<?=$attach['att_idx']?>"> 파일 삭제</label>
  81. </div>
  82. </div>
  83. <?php endforeach;?>
  84. </div>
  85. </div>
  86. </div>
  87. <?php endif;?>
  88. </div>
  89. <div class="text-center MT15">
  90. <button class="btn btn-primary">작성하기</button>
  91. </div>
  92. <?=$form_close?>