묻고답하기
게시판 저장시 문제
2015.06.28 20:06
게시판 저장시 PC와 모바일이 다르게 저장되는 문제로 문의 드립니다.
xe 기본 게시판을 쓰고 있고 스킨은 스케치북 게시판 스킨을 쓰고 있습니다.
제가 몇가지 수정을 했는데 문서 저장시 PC 로는 html 코드가 정상 저장이 되는데
모바일로 저장하면 html 코드가 이런식으로 저장되니 나중에 보기를 하면 html 코드가 보기 화면에 그대로 노출되네요.
쓰기 파일은 같은 화일인데 저장시에 왜 다르게 저장이 되는지 어디에 문제가 있는지 알수가 없네요 ㅠ
아래는 스킨 코드입니다.
write_form.html 파일이구요. 모바일이랑 PC랑 같은 페이지로 사용하는데 저장은 왜 다르게 되는지 잘 모르겠네요 ㅠ
초보라 도움부탁드립니다 ㅠ
=============================
<include target="_header.html" />
<form action="./" method="post" onsubmit="return procFilter(this, window.insert)" class="bd_wrt main clear">
<input type="hidden" name="mid" value="{$mid}" />
<!--@if(!$oDocument->getContentText() && $mi->content_default)-->
<input type="hidden" name="content" value="{htmlspecialchars($mi->content_default)}" />
<!--@else-->
<input type="hidden" name="content" value="{$oDocument->getContentText()}" />
<!--@end-->
<input type="hidden" name="document_srl" value="{$document_srl}" />
<!--// 상단 : 카테고리, 제목 -->
<table class="bd_wrt_hd" border="0" cellspacing="0" width="100%">
<tr>
<td>
<select cond="$mi->use_category=='Y'" name="category_srl" class="category">
<option value="">{$lang->category}</option>
<option loop="$category_list => $val" disabled="disabled"|cond="!$val->grant" value="{$val->category_srl}" selected="selected"|cond="$val->grant&&$val->selected||$val->category_srl==$oDocument->get('category_srl')">
{str_repeat(" ",$val->depth)} {$val->title} ({$val->document_count})
</option>
</select>
</td>
<td width="100%" style="padding-right:12px">
<!--// 태그, 글쓴이, 비밀번호 등 -->
<div class="edit_opt">
<block cond="!$is_logged">
<span class="itx_wrp">
<label for="nick_name">{$lang->writer}</label>
<input type="text" name="nick_name" id="nick_name" value="{htmlspecialchars($oDocument->get('nick_name'))}" class="itx n_p" />
</span>
<span class="itx_wrp">
<label for="password">{$lang->password}</label>
<input type="password" name="password" id="password" class="itx n_p" />
</span>
<!--// 비밀글 -->
<div cond="is_array($status_list)" class="section" style="display:none">
<!--@foreach($status_list AS $key=>$value)-->
<input type="radio" name="status" value="{$key}" id="{$key}" <!--@if($oDocument->get('status') == $key || ($key != 'PUBLIC' && !$document_srl))-->checked="checked"<!--@end--> />
</div>
<div class="section" style="display:none">
<input type="checkbox" name="comment_status" value="ALLOW" checked="checked"|cond="$oDocument->allowComment()" id="comment_status" />
<label for="comment_status">{$lang->allow_comment}</label>
</div>
<!--@end-->
</block>
</div>
<!--// 제목 -->
<span class="itx_wrp">
<label for="postTitle">{$lang->title}</label>
<input cond="$oDocument->getTitleText()" type="text" name="title" class="itx" id="postTitle" title="{$lang->title}" value="{htmlspecialchars($oDocument->getTitleText())}" />
<input cond="!$oDocument->getTitleText()" type="text" name="title" class="itx" id="postTitle" title="{$lang->title}" />
</span>
</td>
<td cond="$is_logged && !$oDocument->isExists() || $oDocument->get('status')=='TEMP'"><button type="button" class="btn" onclick="doDocumentLoad(this);">{$lang->cmd_load}</button></td>
</tr>
</table>
<table cond="count($extra_keys)" class="exForm bd_tb">
<tr loop="$extra_keys=>$key,$val">
<th scope="row"><em cond="$val->is_required=='Y'">*</em> {$val->name}</th>
<td>{$val->getFormHTML()}</td>
</tr>
</table>
<!--// 에디터 출력 -->
<div class="get_editor">{$oDocument->getEditor()}</div>
<load target="js/editor.js" />
<!--// 글쓰기 옵션 체크 -->
<div class="opt_chk clear">
<div class="section">
<block cond="$grant->manager || $mi->tl_color=='1'">
<div class="color_box_wrp">
<a href="#" class="color_box_btn itx" id="tl_preview_text" style="color:#{$oDocument->get('title_color')}"|cond="$oDocument->get('title_color')" onclick="jQuery(this).next().fadeToggle();return false">{$lang->title_color} <span class="arrow down"></span></a>
<div class="color_box">
<div class="color_box_hd">
<span id="tl_preview_color" class="preview_color itx" style="background-color:#{$oDocument->get('title_color')}"|cond="$oDocument->get('title_color')"></span>
<b>#</b><input type="text" name="title_color" id="tl_preview_code" size="6" maxlength="6" class="itx" value="{$oDocument->get('title_color')}" onkeyup="manual_select_color('tl',this)"/>
<a href="#" class="er btn">{$lang->cmd_reset}</a>
</div>
<script type="text/javascript">
printColor('tl');
</script>
<button type="button" class="close" title="{$lang->cmd_close}" onclick="jQuery(this).parent().fadeOut().prev().focus()">X</button>
</div>
</div>
<input type="checkbox" name="title_bold" id="title_bold" value="Y" checked="checked"|cond="$oDocument->get('title_bold')=='Y'" style="margin-left:8px" />
<label for="title_bold">{$lang->title_bold}</label>
</block>
<block cond="$grant->manager">
<input type="checkbox" name="is_notice" value="Y" checked="checked"|cond="$oDocument->isNotice()" id="is_notice" />
<label for="is_notice">{$lang->notice}</label>
</block>
</div>
</div>
<div cond="$mi->cmt_wrt=='sns'" class="sns_wrt">
<p>※ {$lang->sns_wrt}.</p>
<img class="zbxe_widget_output" widget="socialxe_info" colorset="{$mi->colorset}" skin="default" />
</div>
<!--// 등록 -->
<div class="regist">
<button cond="$is_logged && !$oDocument->isExists() || $oDocument->get('status')=='TEMP'" type="button" onclick="doDocumentSave(this);" class="bd_btn temp">{$lang->cmd_temp_save}</button>
<input type="button" value="{$lang->cmd_preview}" onclick="doDocumentPreview(this);return false" class="bd_btn m_no" />
<input type="submit" value="{$lang->cmd_registration}" class="bd_btn blue" />
<button type="button" onclick="history.back()" class="bd_btn cancle">{$lang->cmd_back}</button>
</div>
</form>
<include target="_footer.html" />