게시판 카테고리 url 부분.. 재질문

빠른답변과 정말 감사하고 죄송합니다...

저의 설명이 부족한탓에 이미지 한번 더 첨부하겠습니다.

알려주신 코드에서는 문제해결이 되지않아 다시한번 실례를 무릎쓰고 코드를 남깁니다.

 

해당 페이지 주소입니다

http://kggagu.co.kr/ㄹㅇㅁㄹㅇㅁㄹ/

 

아래는 수정한 코드입니다.

<div id="kboard-pure-gallery-list">
	
	<div class="kboard-control">
		<div class="kboard-control-search">
			<a href="#" onclick="kboard_pure_gallery_search_toggle();return false;" title="<?php echo __('Search', 'kboard')?>">
			<img src="<?php echo $skin_path?>/images/icon-search.png" alt="<?php echo __('Search', 'kboard')?>"></a>
		</div>
		<?php if($board->isWriter()):?>
		<div class="kboard-control-write">
			<a href="<?php echo $url->set('mod', 'editor')->toString()?>" title="<?php echo __('New', 'kboard')?>"><img src="<?php echo $skin_path?>/images/icon-write.png" alt="<?php echo __('New', 'kboard')?>"></a>
		</div>
		<?php endif?>
	</div>
	
	<!-- 검색폼 시작 -->
	<div class="kboard-pure-gallery-search">
		<form id="kboard-search-form-<?php echo $board->id?>" method="get" action="<?php echo $url->toString()?>">
			<?php echo $url->set('pageid', '1')->set('target', '')->set('keyword', '')->set('mod', 'list')->toInput()?>
			<select name="target">
				<option value=""><?php echo __('All', 'kboard')?></option>
				<option value="title"<?php if(kboard_target() == 'title'):?> selected<?php endif?>><?php echo __('Title', 'kboard')?></option>
				<option value="content"<?php if(kboard_target() == 'content'):?> selected<?php endif?>><?php echo __('Content', 'kboard')?></option>
				<option value="member_display"<?php if(kboard_target() == 'member_display'):?> selected<?php endif?>><?php echo __('Author', 'kboard')?></option>
			</select>
			<input type="text" name="keyword" value="<?php echo kboard_keyword()?>" placeholder="<?php echo __('Search', 'kboard')?>...">
			<button type="submit" class="kboard-pure-gallery-button-small"><?php echo __('Search', 'kboard')?></button>
		</form>
	</div>
	<!-- 검색폼 끝 -->
	
	<?php if($board->use_category == 'yes'):?>

<?php
$category2 = array(
	'뷰로맥스' => array('파티션'),
	'일룸' => array('의자2', '의자2-1'),
	'현대리바트' => array('칠판2', '칠판2-1'),
	'카' => array('연필2', '연필2-1'),
);

$category3 = array(
	'파티션' => array('AP 66T','RP 65T','EP 45T'),
	'의자2' => array('AP 66T','RP 65T','EP 45T'),
	'칠판2' => array('칠판3'),
	'연필2' => array('연필3'),
);
?>

<?php if(kboard_keyword()):?>
<?php
	global $wpdb;
	$search_keyword = kboard_keyword();
	$result = $wpdb->get_results("SELECT DISTINCT `category1` FROM `{$wpdb->prefix}kboard_board_content` WHERE `board_id` = '{$board->id}' AND (`title` LIKE '%{$search_keyword}%' OR `content` LIKE '%{$search_keyword}%')");
?>

<?php foreach($result as $value):?>
<!--<span style="display:inline-block; width:200px; height:30px; border:1px solid black; color:blue; text-align:center; line-height:30px;"><?php echo $value->category1?></span>-->
<?php endforeach?>
<?php endif?>

<!-- 카테고리 시작 -->
<!--
<div class="kboard-category category-mobile">
	<form id="kboard-category-form-<?php echo $board->id?>" method="get" action="<?php echo $url->toString()?>">
		<?php echo $url->set('pageid', '1')->set('category1', '')->set('category2', '')->set('target', '')->set('keyword', '')->set('mod', 'list')->toInput()?>
		
		<?php if($board->initCategory1()):?>
			<select name="category1" onchange="jQuery('#kboard-category-form-<?php echo $board->id?>').submit();">
				<option value=""><?php echo __('All', 'kboard')?></option>
				<?php while($board->hasNextCategory()):?>
				<option value="<?php echo $board->currentCategory()?>"<?php if(kboard_category1() == $board->currentCategory()):?> selected<?php endif?>><?php echo $board->currentCategory()?></option>
				<?php endwhile?>
			</select>
		<?php endif?>
		
		<?php if(kboard_category1() && $category2):?>
			<select name="category2" onchange="jQuery('#kboard-category-form-<?php echo $board->id?>').submit();">
				<option value=""><?php echo __('All', 'kboard')?></option>
				<?php foreach($category2[kboard_category1()] as $category2_name):?>
				<option value="<?php echo $category2_name?>"<?php if(kboard_category2() == $category2_name):?> selected<?php endif?>><?php echo $category2_name?></option>
				<?php endforeach?>
			</select>
		<?php endif?>
	</form>
</div>
-->

<div class="kboard-category category-pc">
<?php if(kboard_keyword()):?>
<ul class="kboard-category-list">
	<li<?php if(!kboard_category1()):?> class="kboard-category-selected"<?php endif?>><a href="<?php echo $url->set('category1', '')->set('category2', '')->set('pageid', '1')->set('target', '')->set('keyword', '')->set('mod', 'list')->tostring()?>"><?php echo __('All', 'kboard')?></a></li>
	<?php foreach($result as $value):?>
	<li<?php if($value->category1 == $_GET['category1']):?> class="kboard-category-selected"<?php endif?>>
		<a href="<?php echo $url->set('category1', $board->currentCategory())->set('category1', $value->category1)->set('pageid', '1')->set('target', '')->set('keyword', kboard_keyword())->set('mod', 'list')->set('compare', '')->toString()?>"><?php echo $value->category1?></a>
	</li>
	<?php endforeach?>
</ul>
<?php else:?>
	<?php if($board->initCategory1()):?>
		<ul class="kboard-category-list">
			<li<?php if(!kboard_category1()):?> class="kboard-category-selected"<?php endif?>><a href="<?php echo $url->set('category1', '')->set('pageid', '1')->set('target', '')->set('keyword', '')->set('mod', 'list')->tostring()?>"><?php echo __('All', 'kboard')?></a></li>
			<?php while($board->hasNextCategory()):?>
			<li<?php if(kboard_category1() == $board->currentCategory()):?> class="kboard-category-selected"<?php endif?>>
				<a href="<?php echo $url->set('category1', $board->currentCategory())->set('pageid', '1')->set('target', '')->set('keyword', '')->set('mod', 'list')->toString()?>"><?php echo $board->currentCategory()?></a>
			</li>
			<?php endwhile?>
		</ul>
	<?php endif?>
<?php endif?>
	
	<?php if(kboard_category1() && $category2 && isset($category2[kboard_category1()]) && $category2[kboard_category1()]):?>
		<ul class="kboard-category-list">
			<li<?php if(!kboard_category2()):?> class="kboard-category-selected"<?php endif?>><a href="<?php echo $url->set('category2', '')->set('pageid', '1')->set('target', '')->set('keyword', '')->set('mod', 'list')->tostring()?>"><?php echo __('All', 'kboard')?></a></li>
			<?php foreach($category2[kboard_category1()] as $category2_name):?>
			<li<?php if(kboard_category2() == $category2_name):?> class="kboard-category-selected"<?php endif?>>
				<a href="<?php echo $url->set('category2', $category2_name)->set('pageid', '1')->set('target', '')->set('keyword', '')->set('mod', 'list')->toString()?>"><?php echo $category2_name?></a>
			</li>
			<?php endforeach?>
		</ul>
	<?php endif?>
	
	<?php if(kboard_category2() && $category3 && isset($category3[kboard_category2()]) && $category3[kboard_category2()]):?>
		<ul class="kboard-category-list">
			<li<?php if(!kboard_keyword()):?> class="kboard-category-selected"<?php endif?>><a href="<?php echo $url->set('category3', '')->set('pageid', '1')->set('target', '')->set('keyword', '')->set('mod', 'list')->tostring()?>"><?php echo __('All', 'kboard')?></a></li>
			<?php foreach($category3[kboard_category2()] as $category3_name):?>
			<li<?php if(kboard_target() == 'kboard_option_category3' && kboard_keyword() == $category3_name):?> class="kboard-category-selected"<?php endif?>>
				<a href="<?php echo $url->set('target', 'kboard_option_category3')->set('keyword', $category3_name)->set('pageid', '1')->set('compare', '=')->set('mod', 'list')->toString()?>"><?php echo $category3_name?></a>
			</li>
			<?php endforeach?>
		</ul>
	<?php endif?>
</div>
<!-- 카테고리 끝 -->
<?php endif?>
	
	<!-- 리스트 시작 -->
	<ul class="kboard-pure-gallery-list">
		<?php while($content = $list->hasNextNotice()):?>
		<li class="kboard-list-item<?php if($content->uid == kboard_uid()):?> kboard-list-selected<?php endif?>">
			<a href="<?php echo $url->set('uid', $content->uid)->set('mod', 'document')->toString()?>#kboard-document">
				<div class="kboard-list-thumbnail">
					<?php if($content->getThumbnail(500, 500)):?>
					<div class="kboard-list-thumbnail-child" style="background-image:url(<?php echo $content->getThumbnail(500, 500)?>)"></div>
					<?php endif?>
					<?php if(isset($content->attach->over_image)):?>
					<div class="kboard-list-thumbnail-over-background"></div>
					<div class="kboard-list-thumbnail-over-image"><img src="<?php echo site_url($content->attach->over_image[0])?>" alt=""></div>
					<?php endif?>
				</div>
				<div class="kboard-list-notice"><span class="kboard-oneticon-new-notify"><?php echo __('Notice', 'kboard')?></span></div>
				<div class="kboard-list-title"><div class="kboard-oneticon-cut-strings">
					<?php if($content->secret):?><img src="<?php echo $skin_path?>/images/icon-lock.png" class="kboard-icon-lock" alt="<?php echo __('Secret', 'kboard')?>"><?php endif?>
					<?php echo $content->title?>
				</div></div>

				<!--<div class="kboard-list-user"><?php echo apply_filters('kboard_user_display', $content->member_display, $content->member_uid, $content->member_display, 'kboard', $boardBuilder)?></div>-->
			</a>
		</li>
		<?php endwhile?>
		<?php while($content = $list->hasNext()):?>
		<li class="kboard-list-item<?php if($content->uid == kboard_uid()):?> kboard-list-selected<?php endif?>">
			<a href="<?php echo $url->set('uid', $content->uid)->set('mod', 'document')->toString()?>#kboard-document">
				<div class="kboard-list-thumbnail">
					<?php if($content->getThumbnail(500, 500)):?>
					<div class="kboard-list-thumbnail-child" style="background-image:url(<?php echo $content->getThumbnail(500, 500)?>)"></div>
					<?php endif?>
					<?php if(isset($content->attach->over_image)):?>
					<div class="kboard-list-thumbnail-over-background"></div>
					<div class="kboard-list-thumbnail-over-image"><img src="<?php echo site_url($content->attach->over_image[0])?>" alt=""></div>
					<?php endif?>
				</div>
				<!--<div class="kboard-list-new"><?php if($content->isNew()):?><span class="kboard-oneticon-new-notify">New</span><?php endif?></div>-->
				<div class="kboard-list-title"><div class="kboard-oneticon-cut-strings">
					<?php if($content->secret):?><img src="<?php echo $skin_path?>/images/icon-lock.png" class="kboard-icon-lock" alt="<?php echo __('Secret', 'kboard')?>"><?php endif?>
					<?php echo $content->title?>
				</div></div>
				<div class="kboard-list-title kboard-list-user" style="color:blue;"><div class="kboard-oneticon-cut-strings">
					<?php echo $content->option->{tablespac3}?>
				</div></div>
				

				<!--<div class="kboard-list-user"><?php echo apply_filters('kboard_user_display', $content->member_display, $content->member_uid, $content->member_display, 'kboard', $boardBuilder)?></div>-->
			</a>
		</li>
		<?php endwhile?>
	</ul>
	<!-- 리스트 끝 -->
	
	<!-- 페이징 시작 -->
	<div class="kboard-pagination">
		<ul class="kboard-pagination-pages">
			<?php echo kboard_pagination($list->page, $list->total, $list->rpp)?>
		</ul>
	</div>
	<!-- 페이징 끝 -->
	
	<div class="kboard-pure-gallery-poweredby">
		<a href="http://www.cosmosfarm.com/products/kboard" onclick="window.open(this.href);return false;" title="<?php echo __('KBoard is the best community software available for WordPress', 'kboard')?>">Powered by KBoard</a>
	</div>
</div>




<?php wp_enqueue_script('pure-gallery-list', "{$skin_path}/list.js", array(), KBOARD_VERSION, true)?>
워드프레스 에러 기술지원 서비스 전문가에게 맡기세요
워드프레스 에러 기술지원 서비스 전문가에게 맡기세요
  • 안녕하세요~^^

    아래의 코드를 찾아서

    <ul class="kboard-category-list">
    	<li<?php if(!kboard_category1()):?> class="kboard-category-selected"<?php endif?>><a href="<?php echo $url->set('category1', '')->set('category2', '')->set('pageid', '1')->set('target', '')->set('keyword', '')->set('mod', 'list')->tostring()?>"><?php echo __('All', 'kboard')?></a></li>
    	<?php foreach($result as $value):?>
    	<li<?php if($value->category1 == $_GET['category1']):?> class="kboard-category-selected"<?php endif?>>
    		<a href="<?php echo $url->set('category1', $board->currentCategory())->set('category1', $value->category1)->set('pageid', '1')->set('target', '')->set('keyword', kboard_keyword())->set('mod', 'list')->set('compare', '')->toString()?>"><?php echo $value->category1?></a>
    	</li>
    	<?php endforeach?>
    </ul>

    아래의 코드로 교체해보세요.

    <ul class="kboard-category-list">
    	<li<?php if(!kboard_category1()):?> class="kboard-category-selected"<?php endif?>><a href="<?php echo $url->set('category1', '')->set('category2', '')->set('pageid', '1')->set('target', '')->set('keyword', '')->set('mod', 'list')->tostring()?>"><?php echo __('All', 'kboard')?></a></li>
    	<?php foreach($result as $value):?>
    	<li<?php if($value->category1 == $_GET['category1']):?> class="kboard-category-selected"<?php endif?>>
    		<a href="<?php echo $url->set('category1', $value->category1)->set('pageid', '1')->set('target', '')->set('keyword', kboard_keyword())->set('mod', 'list')->set('compare', '')->toString()?>"><?php echo $value->category1?></a>
    	</li>
    	<?php endforeach?>
    </ul>

     

    적용을 해도 계속해서 동작에 문제가 있다면

    저희 고객지원 쪽 이메일로 워드프레스 관리자 계정과 FTP 접속 정보를 보내주시면 점검해드리겠습니다.

    저희 쪽 홈페이지에서 테스트했을 땐 별다른 문제가 없었거든요.

    고맙습니다.

  • 감사합니다 !! 적용이 잘 되었습니다.

    문제는 제가 스킨을 -2로 지정해두고 기본퓨어스킨에서만 계속 수정하였던 점입니다..ㅠㅠ 정말 죄송합니다.

좋은 정보와 인맥을 동시에, 워드프레스 사용자 단톡방 참여하기