그룹 게시판(최신글 게시판??)에서 각 게시판별 최신글 목록을 '목록보기 권한'에 따라 나타나게 하는 방법 질문 드립니다.

그룹 게시판(최신글 게시판??)에서 각 게시판별 최신글 목록을 '목록보기 권한'에 따라 나타나게 하는 방법 질문 드립니다.

QA

그룹 게시판(최신글 게시판??)에서 각 게시판별 최신글 목록을 '목록보기 권한'에 따라 나타나게 하는 방법 질문 드립니다.

본문

안녕하세요?

 

하나의 메뉴(그룹)에는, 여러개의 게시판이 존재 합니다.

 

이 메뉴 (그룹)을 클릭하면, 각 게시판들의 최신글들을 불러모아 나타내는 하나의 페이지가 나타납니다.

 

이 페이지에서 각 게시판별 설정된 '목록보기 권한'에 따라 달리 보여주고 싶습니다.

 

예를 들어

 

A, B, C, D 게시판이 존재하고, 각 게시판의 목록보기 권한은 차례대로 2, 3, 4, 5 라고 하면,

 

5레벨의 회원은 ABCD 네 게시판 모두에 해당하는 최신글 목록이 보여지고

 

3레벨의 회원은 AB 최신글 목록은 보여지지만, CD 게시판의 최신글은 보여지지 않게 하고 싶습니다.

 

위의 방법을 구현하려면 어떻게 해야되는지요?

 

 

최신글 함수는

 <div style="float:left;margin-right:10px;width:710px;height:350px"​>
        <?=latest('basic2', 'board1',5, 20); ?>
  </div>

 <div style="float:left;margin-right:10px;width:710px;height:350px"​>
        <?=latest('basic2', 'board2',5, 20); ?>
  </div>

 <div style="float:left;margin-right:10px;width:710px;height:700px"​>
        <?=latest('basic2', 'board3',5, 20); ?>
  </div>

 <div style="float:left;margin-right:10px;width:710px;height:700px"​>
        <?=latest('basic2', 'board4',5, 20); ?>
  </div>

...

...

 

이 형태를 사용하고 있습니다.

이 질문에 댓글 쓰기 :

답변 1

if ($member[mb_level] > 3) {

  <div style="float:left;margin-right:10px;width:710px;height:350px"​> 
        <?=latest('basic2', 'A게시판',5, 20); ?>
  </div> 

  <div style="float:left;margin-right:10px;width:710px;height:350px"​> 
        <?=latest('basic2', 'B게시판',5, 20); ?>
  </div> 

}else if($member[mb_level] > 5){

<div style="float:left;margin-right:10px;width:710px;height:350px"​> 
        <?=latest('basic2', 'board1',5, 20); ?>
  </div>

 <div style="float:left;margin-right:10px;width:710px;height:350px"​> 
        <?=latest('basic2', 'board2',5, 20); ?>
  </div>

 <div style="float:left;margin-right:10px;width:710px;height:700px"​> 
        <?=latest('basic2', 'board3',5, 20); ?>
  </div>

 <div style="float:left;margin-right:10px;width:710px;height:700px"​> 
        <?=latest('basic2', 'board4',5, 20); ?>
  </div>

} 

이런식으로 조건문으로 로직 구성해야 하지 않을까요??

답변을 작성하시기 전에 로그인 해주세요.
전체 65
QA 내용 검색

회원로그인

(주)에스아이알소프트 / 대표:홍석명 / (06211) 서울특별시 강남구 역삼동 707-34 한신인터밸리24 서관 1402호 / E-Mail: admin@sir.kr
사업자등록번호: 217-81-36347 / 통신판매업신고번호:2014-서울강남-02098호 / 개인정보보호책임자:김민섭(minsup@sir.kr)
© SIRSOFT