<?xml version="1.0" encoding="UTF-8" ?>
<rss version="2.0">
	<channel>
				<title><![CDATA[특정 글에만 'new' 표시를 유지하고 싶을 때...?]]></title>
		<link>https://www.cosmosfarm.com/threads/rss/document/21730</link>
		<description><![CDATA[<p>안녕하세요.</p>

<p>워드프레스 게시판 KBoard(케이보드) 사용중입니다.</p>

<p>케이보드 대시보드에서 새글 'new' 표시를 3일로 설정해 두었습니다.</p>

<p>그런데 특정 게시글에만 오랫동안 'new'표시를 해두고 싶습니다.</p>

<p>혹시 방법이 있을까요?</p>
]]></description>
		<copyright>Copyright 2026, 코스모스팜</copyright>
				<item>
			<title><![CDATA[감사합니다!!
]]></title>
			<link>https://www.cosmosfarm.com/threads/document/21937</link>
			<description><![CDATA[<p>감사합니다!!</p>
]]></description>
			<author>2kiya</author>
			<pubDate>Sat, 28 Apr 2018 13:57:08 +0000</pubDate>
			<category>KBoard</category>
		</item>
				<item>
			<title><![CDATA[안녕하세요.

특정 게시글이 여러개 일때는

아래의 코드처럼 해주시면 됩니다.


add_filter('kboard_c...]]></title>
			<link>https://www.cosmosfarm.com/threads/document/21790</link>
			<description><![CDATA[<p>안녕하세요.</p>

<p>특정 게시글이 여러개 일때는</p>

<p>아래의 코드처럼 해주시면 됩니다.</p>

<pre>
<code class="language-php">add_filter('kboard_content_is_new', 'my_kboard_content_is_new', 10, 2);
function my_kboard_content_is_new($is_new, $content){
	if(in_array($content-&gt;uid, array('1', '2','3'))){ // 게시글 uid 값을 체크합니다.
		$is_new = true;
	}
	return $is_new;
}</code></pre>

<p>in_array에 대한 자세한 내용은 아래의 링크를 참고해보시겠어요?</p>

<p><a href="http://php.net/manual/kr/function.in-array.php" target="_blank">http://php.net/manual/kr/function.in-array.php</a></p>

<p>고맙습니다.</p>
]]></description>
			<author>스레드봇</author>
			<pubDate>Tue, 24 Apr 2018 23:54:29 +0000</pubDate>
			<category>KBoard</category>
		</item>
				<item>
			<title><![CDATA[아 그럼 특정 게시글이 두개 이상일 때도 가능한가요?]]></title>
			<link>https://www.cosmosfarm.com/threads/document/21782</link>
			<description><![CDATA[<p>아 그럼 특정 게시글이 두개 이상일 때도 가능한가요?</p>]]></description>
			<author>2kiya</author>
			<pubDate>Tue, 24 Apr 2018 15:37:29 +0000</pubDate>
			<category>KBoard</category>
		</item>
				<item>
			<title><![CDATA[와우...큰 기대없이 혹시나 하고 질문드렸는데 간단하게 해결해주시네요.

덕분에 원하는 사이트를 구현...]]></title>
			<link>https://www.cosmosfarm.com/threads/document/21780</link>
			<description><![CDATA[<p>와우...큰 기대없이 혹시나 하고 질문드렸는데 간단하게 해결해주시네요.</p>

<p>덕분에 원하는 사이트를 구현해나가고 있어서 정말 감사드립니다.</p>]]></description>
			<author>2kiya</author>
			<pubDate>Tue, 24 Apr 2018 15:31:09 +0000</pubDate>
			<category>KBoard</category>
		</item>
				<item>
			<title><![CDATA[안녕하세요~^^

먼저 /wp-content/plugins/kboard/class/KBContent.class.php 파일을 수정해주세요.

 
...]]></title>
			<link>https://www.cosmosfarm.com/threads/document/21736</link>
			<description><![CDATA[<p>안녕하세요~^^</p>

<p>먼저 /wp-content/plugins/kboard/class/KBContent.class.php 파일을 수정해주세요.</p>

<p> </p>

<p>1. KBContent.class.php 파일에서 아래 코드를 찾아주세요.</p>

<pre>
<code class="language-php">public function isNew(){
	if($this-&gt;uid){
		$notify_time = kboard_new_document_notify_time();
		if((current_time('timestamp')-strtotime($this-&gt;date)) &lt;= $notify_time &amp;&amp; $notify_time != '1'){
			return true;
		}
	}
	return false;
}</code></pre>

<p> </p>

<p>2. 찾은 코드를 아래 코드로 교체 해주세요.</p>

<pre>
<code class="language-php">public function isNew(){
	$is_new = false;
	if($this-&gt;uid){
		$notify_time = kboard_new_document_notify_time();
		if((current_time('timestamp')-strtotime($this-&gt;date)) &lt;= $notify_time &amp;&amp; $notify_time != '1'){
			$is_new = true;
		}
	}
	return apply_filters('kboard_content_is_new', $is_new, $this);
}</code></pre>

<p> </p>

<p>3. 테마의 functions.php 파일에 아래 코드를 추가해주세요.</p>

<pre>
<code class="language-php">add_filter('kboard_content_is_new', 'my_kboard_content_is_new', 10, 2);
function my_kboard_content_is_new($is_new, $content){
	if($content-&gt;uid == '1'){ // 게시글 uid 값을 체크합니다.
		$is_new = true;
	}
	return $is_new;
}</code></pre>

<p>게시글의 uid 값은 적절히 바꿔주셔야 합니다.</p>

<p> </p>

<p>KBContent.class.php 파일의 내용은 기본으로 적용해서 업데이트하도록 하겠습니다.</p>

<p>고맙습니다.</p>
]]></description>
			<author>스레드봇</author>
			<pubDate>Mon, 23 Apr 2018 14:32:24 +0000</pubDate>
			<category>KBoard</category>
		</item>
			</channel>
</rss>