묻고답하기
page_full_width" class="col-xs-12" |cond="$__Context->page_full_width">
확장변수에서 이미지 경로를 받아 출력하기
2014.07.16 20:35
이걸 하려고 일단 link_img라는 확장변수를 url 형식으로 추가하였습니다
테스트 글을 쓸 때 이 확장변수에 http://주소/img.jpg 이런 경로로 적었고
그런 다음에 list.html를 고쳤습니다.
<include target="_header.html" /> <include cond="$oDocument->isExists()" target="_read.html" /> <div class="board_list" id="board_list"> <p cond="!$document_list" style="text-align:center">{$lang->no_documents}</p> <div cond="$document_list || $notice_list"> <!-- NOTICE --> <div class="notice"> <ul class="link_notice"> <li loop="$notice_list=>$document"> <div class="item"> <div class="link_header"> <a href="{$document->getExtraEidValue('link_url')}" target="_blank">{$document->getTitle()}</a> <a cond="$grant->manager" href="{getUrl('document_srl',$document->document_srl, 'listStyle', $listStyle, 'cpage','')}">수정</a> </div> <div class="link_body"> <!--@if($document->getExtraEidValue('link_img'))--> <a href="{$document->getExtraEidValue('link_url')}" target="_blank"> <img class="link_img" src="{$document->getExtraEidValue('link_img')}" width="90px" height="30px" /> </a> <!--@else--> <span class="no_img">no image</span> <!--@end--> </div> </li> </ul> </div> <!-- /NOTICE --> <!-- LIST --> <div class="list"> <ul class="link_list"> <li loop="$document_list=>$document"> <div class="item"> <div class="link_header"> <a href="{$document->getExtraEidValue('link_url')}" target="_blank">{$document->getTitle()}</a> <a cond="$grant->manager" href="{getUrl('document_srl',$document->document_srl, 'listStyle', $listStyle, 'cpage','')}">수정</a> </div> <div class="link_body"> <!--@if($document->getExtraEidValue('link_img'))--> <a href="{$document->getExtraEidValue('link_url')}" target="_blank"> <img class="link_img" src="{$document->getExtraEidValue('link_img')}" width="90px" height="30px" /> </a> <!--@else--> <span class="no_img">no image</span> <!--@end--> </div> </li> </ul> </div> <!-- /LIST --> </div> <div class="list_footer"> <div class="pagination" cond="$document_list || $notice_list"> <a href="{getUrl('page','','document_srl','','division',$division,'last_division',$last_division)}" class="direction prev"> <</a> <block loop="$page_no=$page_navigation->getNextPage()"> <strong cond="$page==$page_no">{$page_no}</strong> <a cond="$page!=$page_no" href="{getUrl('page',$page_no,'document_srl','','division',$division,'last_division',$last_division)}">{$page_no}</a> </block> <a href="{getUrl('page',$page_navigation->last_page,'document_srl','','division',$division,'last_division',$last_division)}" class="direction next">> </a> </div> <div class="btnArea"> <a href="{getUrl('act','dispBoardWrite','document_srl','')}" class="board_btn">{$lang->cmd_write}</a> <a cond="$grant->manager" href="{getUrl('','module','document','act','dispDocumentManageDocument')}" class="board_btn" onclick="popopen(this.href,'manageDocument'); return false;">{$lang->cmd_manage_document}</a> </div> <button type="button" class="bsToggle" title="{$lang->cmd_search}">{$lang->cmd_search}</button> <form cond="$grant->view" action="{getUrl()}" method="get" onsubmit="return procFilter(this, search)" id="board_search" class="board_search" no-error-return-url="true"> <input type="hidden" name="vid" value="{$vid}" /> <input type="hidden" name="mid" value="{$mid}" /> <input type="hidden" name="category" value="{$category}" /> <input type="text" name="search_keyword" value="{htmlspecialchars($search_keyword)}" title="{$lang->cmd_search}" class="iText" /> <select name="search_target"> <option loop="$search_option=>$key,$val" value="{$key}" selected="selected"|cond="$search_target==$key">{$val}</option> </select> <button type="submit" class="board_btn" onclick="xGetElementById('board_search').submit();return false;">{$lang->cmd_search}</button> <a cond="$last_division" href="{getUrl('page',1,'document_srl','','division',$last_division,'last_division','')}" class="btn">{$lang->cmd_search_next}</a> </form> <!-- <a href="{getUrl('act','dispBoardTagList')}" class="tagSearch" title="{$lang->tag}">{$lang->tag}</a> --> </div> <include target="_footer.html" />
페이지 자체가 아예 깨져 버립니다.
어떻게 해야 좋을까요?
자체 해결했습니다. 태그를 제대로 닫지 않은 초보적인 실수를 저질렀군요;;;