묻고답하기

지금 사용중인 위젯 스킨이 doorweb 최신글 ,댓글 위젯 스킨 ver. 1.1 을 사용 중입니다.

아주 좋은 위젯이라 사용을 하는데...약간의 추가사항은 새글이나 댓글이 등록되면 글 앞이나 뒤에 NEW 아이콘을 넣고 싶습니다.

소스를 보아도, 워낙 프로그램에 지식이 없어서...고수분들의 도움이 필요합니다.

감사합니다.

tab.jpg   이렇게요...아래 소스 있습니다.

*만약 프로그램 원작자에게 저작원 영향이 있는 문의라면 삭제하겠습니다. 

----------------------------------------------------------------------------------------------

<load target="smart_popular.css" />

{@
 $tabc=count($widget_info->tab_view_arr);
 $optc=count($widget_info->option_view_arr);
 $li_width = $widget_info->widget_widths/$tabc;
 $img_width = $widget_info->thumbnail_width-2;
 $img_height = $widget_info->thumbnail_height-2;
}

<!--@if(!$global['popsid'])-->{@ $__Context->global['popsid'] = 1}<!--@endif-->{@ $__Context->global['popsid']++}

<div id="popular{$global['popsid']}" class="doorweb-popular newClear">
 <!--// TAB Start -->
 <div class="tabs_items newClear" >
  <ul>
   <block loop="$i=0; $i<$tabc; $i++">
    <!--@if($widget_info->tab_view_arr[$i]=='popular')-->
     <li><a id="pd_link_s{$global['popsid']}" class="tabs_active"|cond="$widget_info->tab_view_arr[0]=='popular'" href="#">{$lang->ip_popular_documents}</a></li>
    <!--@elseif($widget_info->tab_view_arr[$i]=='newestd')-->
     <li><a id="nd_link_s{$global['popsid']}" class="tabs_active"|cond="$widget_info->tab_view_arr[0]=='newestd'" href="#">{$lang->ip_newest_documents}</a></li>
    <!--@elseif($widget_info->tab_view_arr[$i]=='newestc')-->
     <li><a id="nc_link_s{$global['popsid']}" class="tabs_active"|cond="$widget_info->tab_view_arr[0]=='newestc'" href="#">{$lang->ip_newest_comments}</a></li>
                   
    <!--@end-->
   </block>
  </ul>
 </div>
 <!--// TAB End -->
 
 <div class="tabs_inner newClear" >
  <!--// Popular Documents Start -->
  <div id="popular_documents_s{$global['popsid']}" class="tabs_content<!--@if($widget_info->tab_view_arr[0]=='popular')--> tabs_active<!--@endif-->">
   <ul cond="$widget_info->popular_documents">
    <li loop="$widget_info->popular_documents=>$key,$val" class="newClear">
     <a href="{$val->getPermanentUrl()}">
      <block loop="$i=0; $i<$optc; $i++">
      <!--@if($widget_info->option_view_arr[$i]=='image')-->
       
      <!--@elseif($widget_info->option_view_arr[$i]=='title')-->
       <div class="text_title">{$val->getTitle($widget_info->subject_cut_size)} <span class="replyNum" title="Replies" cond="$val->getCommentCount() > 0">({$val->getCommentCount()})</span></div>
      <!--@elseif($widget_info->option_view_arr[$i]=='content')-->
       
      <!--@elseif($widget_info->option_view_arr[$i]=='regdate')-->
       
      <!--@endif-->
      </block>
     </a>
    </li>
   </ul>
  </div>
  <!--// Popular Documents End -->
  
  <!--// Newest Documents Start -->
  <div id="newest_documents_s{$global['popsid']}" class="tabs_content<!--@if($widget_info->tab_view_arr[0]=='newestd')--> tabs_active<!--@endif-->">
   <ul>
    <li loop="$widget_info->newest_documents=>$key,$val" class="newClear">
     <a href="{$val->getPermanentUrl()}">
      <block loop="$i=0; $i<$optc; $i++">
      <!--@if($widget_info->option_view_arr[$i]=='image')-->
       
      <!--@elseif($widget_info->option_view_arr[$i]=='title')-->
       <div class="text_title">{$val->getTitle($widget_info->subject_cut_size)} <span class="replyNum" title="Replies" cond="$val->getCommentCount() > 0"> ({$val->getCommentCount()})</span></div>
      <!--@elseif($widget_info->option_view_arr[$i]=='content')-->
       
      <!--@elseif($widget_info->option_view_arr[$i]=='regdate')-->
       
      <!--@endif-->
      </block>
     </a>
    </li>
   </ul>
  </div>
  <!--// Newest Documents End -->
  
  <!--// Newest Comments Start -->
   
  <div id="newest_comments_s{$global['popsid']}" class="tabs_content<!--@if($widget_info->tab_view_arr[0]=='newestc')--> tabs_active<!--@endif-->">
   <ul>
    <li loop="$widget_info->newest_comments=>$key,$val" class="newClear">
     <a href="{$val->getPermanentUrl()}">
    
       <span class="tabs_content2">{$val->getSummary($widget_info->comment_cut_size)}</span>
   
     </a>

    </li>
   </ul>
  </div>
  <!--// Newest Comments End -->
 </div>
</div>

<script>
jQuery(function($){
 var $popular = $("#popular{$global['popsid']}"),
  $tabs_items = $popular.find(".tabs_items"),
  $tabs_itema = $tabs_items.find("a"),
  $tabs_inner = $popular.find(".tabs_inner");

 var $pds = $("#popular_documents_s{$global['popsid']}"),
  $nds = $("#newest_documents_s{$global['popsid']}"),
  $ncs = $("#newest_comments_s{$global['popsid']}");

 function actTab($tid){
  $tabs_itema.removeClass("tabs_active");
  $tid.addClass("tabs_active");
 }

 function actItem($sid){
  $tabs_inner.find(".tabs_active").removeClass("tabs_active");
  $sid.addClass("tabs_active");
 }

 $tabs_itema.on("mouseover click",function(e){
  e.preventDefault();
  var $tid = $(this);
  actTab($tid);
 });

 $("#pd_link_s{$global['popsid']}").on("mouseover click",function(e){
  e.preventDefault();
  actItem($pds);
 });
 $("#nd_link_s{$global['popsid']}").on("mouseover click",function(e){
  e.preventDefault();
  actItem($nds);
 });
 $("#nc_link_s{$global['popsid']}").on("mouseover click",function(e){
  e.preventDefault();
  actItem($ncs);
 });
});
</script>

 

 

글쓴이 제목 최종 글
XE 공지 글 쓰기,삭제 운영방식 변경 공지 [16] 2019.03.05 by 남기남
박근선 이 페이지의 경로를 알고 싶습니다 [2] file 2017.02.03 by 박근선
영신 회원가입 설정메뉴가 사라졌나요? [1] 2017.02.03 by sejin7940
cherrypower XE 패치하는 방법 좀 부탁드립니다. [2] 2017.02.03 by cherrypower
jesusismylord 스케치북 게시판 웹진형 사용중인데 섬네일이 안뜹니다 ㅜㅜ 계속 썸네일 잘 사용하고 있었어요. [1] file 2017.02.03 by 한돌(漢湥)
yoonsick**** 페이지 수정 버튼을 누르면 흰 바탕만 나오는 경우  
이쩡2 도움 요청드립니다[사례합니다] [6] 2017.02.03 by BRANDYK
김범진 누리고 쇼핑몰에서 마일리지랑 적립금 부분입니다. 꼭 읽어주십쇼 [1] 2017.02.03 by sejin7940
하시아 회원가입이 안됩니다 [1] 2017.02.03 by sejin7940
자유비행 홈피 로그인이 갑자기 되지않습니다. [6] file 2017.02.02 by 자유비행
j0yrid3 업로드기능이 활성화가 아예 안됩니다 ㅠㅠ file  
대박필승 공지사항 상세화면 한글깨짐. [1] file 2017.02.02 by 펭구
국민거풍박풍기 관리자페이지 쉬운설치 메뉴항목 삭제 할수있을까요? [4] 2017.02.02 by 국민거풍박풍기
PLS (xedition 수정 레이아웃) 메뉴 클릭시 같은 페이지내로 이동하는 방법 [3] 2017.02.02 by PLS
마꼬꼬 Nginx에서 특정 url만 https 적용을 안시킬 수 있나요?  
haupt XEDITION 레이아웃에 welcome_main.html 추가하는 방법이 궁금합니다. [1] 2017.02.02 by HowtoXE
홍찬 hover 했을시 다른 class 동작 하는 css [3] 2017.02.02 by HowtoXE
지랭 영문홈페이지 제작할 때 문의점 [2] 2017.02.02 by 지랭
아이에스 최초 설치후 관리자 로그인이 안됩니다. [1] 2017.02.02 by 아이에스
DJ.RDM 다국어 페이지 URL분리 관련 질문입니다 [2] file 2017.02.02 by DJ.RDM
하시아 메뉴 클릭 및 마우스선택시 변경되는 색상 수정하는법 좀 알려주세요 [1] file 2017.02.02 by 제이와이엔소프트
카스터 사이트맵 추가가 안되며 기존 메뉴도 안뜹니다. - 완료 file  
핫센 최근 버전에서 사이트맵(메뉴)를 클릭하면 하얀 공백만 나옵니다. [3] 2017.02.02 by 카스터
쵸코우유 FTP상의 admin계정 DB 생성 방법이 있나요? [1] 2017.02.02 by sejin7940
비둘기 제발 도와주세여ㅠㅠ 게시판 분류ㅠㅠㅠ [1] file 2017.02.02 by 제이와이엔소프트
h2y_07 홈페이지 탭 바꾸기 [1] file 2017.02.02 by 제이와이엔소프트
해피니스 백그라운드에 이미지가 모니터 중앙에 나오게 하려먼 어떻게 해야 하나요? [4] 2017.02.02 by 해피니스
서기에요 게시물 밀림현상 file  
차티스트 XE설치후 게시판만 나오게 해놨는데.. [2] 2017.02.01 by 차티스트
비둘기 추천시 베스트 게시판으로 이동 기능 관련... [1] 2017.02.01 by sejin7940
캐스퍼 게시판에 자바스크립트 사용법.. [1] 2017.02.01 by ksdflc,mei