Beispiel #1
0
<div class="list_top" style="margin-left:55px;margin-bottom:10px">
  <h3><a href="#list_style_2">목록 보기</a></h3>
  <ul class="list_style_2" style="display:none">
<?php foreach ($list as $v) {// 심플리스트
	$category = explode('|',$v['wr_category']);
?>
    <li><a href="<?php echo $v['wr_subject']['href']?>"><?php echo implode('&gt;',$category)?> : <?php echo $v['wr_subject']['text']?>&nbsp;<span class="cnt">(<?php echo $v['cmt_count']?>)</span></a></li>
<?php }?>
  </ul>
</div>

<?php foreach ($list as $v) {
	$imgs = File::Inst()->wr_no($v['wr_no'])->Action('images', 120, 120); // 썸네일 불러오기
	$category = explode('|',$v['wr_category']);
	$link_category = Url::Get(array('ca1'=>$category[0], 'ca2'=>$category[1]));
?>
<span class="blog_date"><?php echo date("n", strtotime($v['wr_datetime']))?>월<br /><?php echo date("j", strtotime($v['wr_datetime']))?>일</span>

<!--Start Blog Div-->
<div class="blog_div">

	<div class="blog_heading">
	<h3><a href="<?php echo $v['wr_subject']['href']?>"><?php echo $v['wr_subject']['text']?></a></h3>
	<p>Posted in <a href="<?php echo $link_category?>" class="category_name"><?php echo implode('-',$category)?></a> by <b><?php echo $v['wr_writer']?></b></p>
	</div><!--End Blog Heading-->

	<p class="blog_comments"><?php echo $v['cmt_count']?></p>
	<br clear="all" />

	<div class="blog_title_border">
Beispiel #2
0
  <p class="right">Read <?php echo number_format($v['wr_hit'])?>, Posted in <a href="<?php echo $link_category?>" class="category_name"><?php echo implode('-',$category)?></a> by <b><?php echo $v['wr_writer']?></b></p>
</div><!--End Blog Heading-->
<br clear="all" />

<div class="blog_title_border" style="margin-bottom:20px">
  <?php if(sizeof($file->Action('images', $this->Config('img_width'), false))!=0) { // 첨부이미지 출력 ?>
  <div class="txt_c" style="margin-bottom:20px"><?php foreach ($file->Action('images', $this->Config('img_width'), false) as $vv) {?>
  <div style="margin-bottom:5px"><img src="<?php echo $vv['link']?>" width="<?php echo $vv['width']?>" height="<?php echo $vv['height']?>"/></div>
  <?php }?></div>
  <?php }?>
  <div style="text-align:right; font-size:11px;margin-bottom:10px"><?php echo 'http://'.$_SERVER['HTTP_HOST'].urldecode(Url::Get());?> <a href="<?php echo 'http://'.$_SERVER['HTTP_HOST'].Url::Get()?>" class="copy">주소복사</a></div>
  <div style="min-height:300px;padding-bottom:20px"><?php echo $v['wr_content']?></div>
<?php if($this->tags){?>
  <div class="tags"><strong>태그(Tags)</strong> :
<?php foreach($this->tags as $vv) { ?>
    <a href="<?php echo Url::Get(array('tag'=>$vv),array('ca1','ca2','wr_no','pg'))?>"><?php echo $vv?></a>&nbsp;
<?php }?>
  </div>
<?php }?>
  <div><?php echo $comments?></div>
  <div style="text-align:right"><?php include $this->path_view('buttons.php')?></div>
</div><!--End Blog Title Border-->          

<div class="list_top" style="margin-bottom:10px">
  <h3>카테고리 다른글&raquo;</h3>
  <ul class="list_style_2">
<?php foreach ($this->sql('view_list_category', $category[0], $category[1]) as $vv) {// 심플리스트
	$category2 = explode('|',$vv['wr_category']);
?>
    <li class="<?php echo $vv['active']?'active':''?>"><a href="<?php echo $vv['wr_subject']['href']?>"><?php echo implode('&gt;',$category2)?> : <?php echo $vv['wr_subject']['text']?>&nbsp;<span class="cnt">(<?php echo $vv['cmt_count']?>)</span></a></li>
<?php }?>
Beispiel #3
0
	if($clear['wr_password']!=$_POST['wr_password_check'])
		Dialog::alert('[비밀번호/비밀번호확인]이 일치하지 않습니다.');
	if(!$clear['wr_password'])
		Dialog::alert('비밀번호를 입력해 주세요.');
	$clear['wr_password'] = $this->Sql('password', $clear['wr_password']);
} else {
	$clear['wr_writer'] = Member::Inst()->mb_nick;
}

// 최근게시글을 위해 게시글이 출력되는 아이디를 저장함
$clear['last_id'] = GV::String('id');

if(!$clear['wr_subject'])	 Dialog::alert('제목을 입력해 주세요.');
if(!$clear['wr_content'])	 Dialog::alert('내용을 입력해 주세요.');
if(!$clear['wr_writer'])	 Dialog::alert('글쓴이를 입력해 주세요.');
if($board->bo_use_category) if(!$clear['wr_category']) Dialog::alert('분류를 선택하세요.');

// 업데이트 날짜
$data['wr_update'] = 'NOW()';

DB::Get()->update($tbn, $clear, ' WHERE wr_no='.$key);
// 파일 업로드
File::Inst()->Action('upload', $key);
$del_files = $_POST[File::Inst()->Config('form_name', 'del')];
if(!is_array($del_files)) $del_files = array();
foreach ($del_files as $v) {
	File::Inst()->Action('delete', $v);
}

Dialog::alertNReplace("게시글 수정을 완료 하였습니다.", Url::Get('',$this->Mode('name')));
Beispiel #4
0
// 세션이 끊어 졌을때만 다시 업데이트 함
if(!$_SESSION[$this->Config('hit_check').$key]) {
	$this->Sql('update_hit',$key);
	$_SESSION[$this->Config('hit_check').$key] = true;
}
$data = $this->Sql('fetch', $key);
$data['wr_content'] = Editor::Inst(Board::Inst()->bo_no($this->bo_no)->bo_editor)->db_out($data['wr_content']);

$this->sql['fetch'.$key] = $data;

// 태그 가져오기
$tags = array();
foreach(Tag::Inst()->Sql('list', $this->bo_no, $key) as $v) {
  $tags[] = array(
    'name'=>$v['tag_name'],
    'link'=>Url::Get(array('tag'=>$v['tag_name']),array('ca1','ca2','wr_no','pg'))
  );
}
$this->tags = $tags;

// 홈페이지 타이틀 설정
$title = array_merge(
  array($data['wr_subject']),
  array($data['wr_category']),
  PageElement::Inst('head')->Config('title')
);

PageElement::Inst('head')->SetConfig('title', '', $title);

// meta description
// descripttion은 과하지 않는것이 좋다.
Beispiel #5
0
$clear['wr_update'] = 'NOW()';

// 분류
if($_POST['ca1']) $clear['wr_category'][] = $_POST['ca1']; 
if($_POST['ca2']) $clear['wr_category'][] = $_POST['ca2']; 
if(is_array($clear['wr_category'])) $clear['wr_category'] = implode('|',$clear['wr_category']); 

$clear['wr_state'] = 0;
if($_POST['opt_notice']) {
	$clear['wr_state'] = $clear['wr_state']|$this->Config('state', 'notice');
}

DB::Get()->update($tbn, $clear, ' WHERE wr_no='.$key, array('wr_update'));

// 태그 입력
$tags = $_POST['tags'];
Tag::Inst()->Action('insert', $bo_no, $key, array_unique(array_filter(explode(',', $tags))));

// 파일 업로드
File::Inst()->Action('upload', $key);
$del_files = $_POST[File::Inst()->Config('form_name', 'del')];
if(!is_array($del_files)) $del_files = array();
foreach ($del_files as $v) {
	File::Inst()->Action('delete', $v);
}

Url::GoReplace(Url::Get('',$this->Mode('name')));



Beispiel #6
0
    $start = $end - $nWidth + 1;
    $end = $pages < $end ? $pages : $end;
    for ($i = $start; $i <= $end; $i++) {
        $class = 'number';
        if ($i == $key) {
            $class .= ' hover';
        }
        if ($i == 1) {
            $link = Url::Get('', $kn);
        } else {
            $link = Url::Get(array($kn => $i));
        }
        $list[] = array('name' => $i, 'class' => $class, 'link' => $link);
    }
    /*
     * 다음링크 생성
     */
    $link = '';
    if ($pages > $key) {
        $link = Url::Get(array($kn => $key + 1));
    } else {
        $link = Url::Get('', $kn);
    }
    $list[] = array('name' => '다음', 'class' => '', 'img' => $this->path_img('paging_next.gif'), 'link' => $link);
    /*
     * 마지막링크 생성
     */
    //if($pages>($key+1)) { }
    $list[] = array('name' => '마지막', 'class' => '', 'img' => $this->path_img('paging_last.gif'), 'link' => Url::Get(array($kn => $pages)));
}
$this->list = $list;
Beispiel #7
0
<?php

if (!defined('__MAGIC__')) {
    exit;
}
include_once $this->path_view('top.php');
?>

<!-- 비밀번호확인 -->
<form method="post" action="<?php 
echo Url::Get('', GV::check);
?>
">
<table class="basic_table">
<thead>
<tr><th>비밀번호 확인</th></tr>
</thead>
<tbody>
<tr>
<td>
<input type="password" name="<?php 
echo GV::password;
?>
"/>
<input type="image" src="<?php 
echo $this->path_img('btn_ok.gif');
?>
" alt="확인"/>
</td>
</tr>
</tbody>
Beispiel #8
0
<?php

if (!defined("__MAGIC__")) {
    exit;
}
$cfg = array();
$cfg['design_mode'] = 'widget';
$cfg['page_mode'] = 'page_edit';
$cfg['is_design'] = GV::String($cfg['design_mode']);
$cfg['link_design'] = Url::Get(array($cfg['design_mode'] => 'true'), array($cfg['page_mode']));
if ($cfg['is_design']) {
    $cfg['link_design'] = Url::Get('', array($cfg['design_mode'], $cfg['page_mode']));
}
$cfg['is_page'] = GV::String($cfg['page_mode']);
$cfg['link_page'] = Url::Get(array($cfg['page_mode'] => 'true'), array($cfg['design_mode']));
if ($cfg['is_page']) {
    $cfg['link_page'] = Url::Get('', array($cfg['page_mode'], $cfg['design_mode']));
}
$cfg['mode']['name'] = 'wgMode';
// widget add info
$cfg['add_widget'] = array('table' => 'wgaif_table', 'field' => 'wgaif_field', 'key' => 'wgaif_key', 'key_name' => 'wgaif_kn', 'pos' => 'wgaif_pos');
// 현재 로그인한 회원정보 저장
$m = Member::Inst();
$cfg['mb'] = array('no' => $m->mb_no, 'name' => $m->mb_name, 'admin' => $m->Action('is_admin'), 'login' => $m->Action('is_login'), 'level' => $m->mb_level);
Beispiel #9
0
#side_tags a.tag_cnt_9,
#side_tags a.tag_cnt_max
{ color:#fff; font-size:16px; font-weight:bold; background-color:#4b5608 }
</style>

<div id="side_tags">
<?php 
foreach ($list as $v) {
    if ($v['cnt'] <= $this->Config('hide_count')) {
        continue;
    }
    ?>
  <a class="tag_cnt_<?php 
    echo $v['cnt'] > 10 ? 'max' : $v['cnt'];
    ?>
" href="<?php 
    echo Url::Get(array('tag' => $v['tag_name']), array('ca1', 'ca2', 'wr_no', 'writeMode', 'pg'));
    ?>
"><?php 
    echo $v['tag_name'];
    ?>
</a>
<?php 
}
?>
<br clear="all" />
</div>



Beispiel #10
0
    	for($i=$start; $i<=$end; $i++) {
    		$class='';
    		if($i==$key) $class='hover';
    		if($i==1) $link = Url::Get('',$kn);
    		else $link = Url::Get(array($kn=>$i));
    		$list[] = array(
    			'name'=>$i,
    			'class'=>$class,
    			'link'=>$link
    		);
    	}
    */
    /*
     * 다음링크 생성
     */
    $link = '';
    if ($pages > $key) {
        $link = Url::Get(array($kn => $key + 1));
        $list[] = array('name' => '다음', 'class' => '', 'link' => $link);
    }
    /*
    * 마지막링크 생성
    	//if($pages>($key+1)) { }
    	$list[] = array(
    		'name'=>'마지막',
    		'class'=>'',
    		'link'=>Url::Get(array($kn=>$pages))
    	);
    */
}
$this->list = $list;
Beispiel #11
0
$rows = $this->Config('rows');
$page = GV::Page() ? GV::Page() : 1;
$tot = $this->Sql('list_cnt');
$from = (intval($page) - 1) * intval($rows) + 1;
$to = $from + $rows - 1;
if ($tot < $to) {
    $to = $tot;
}
$link_prev = '';
$link_next = '';
if ($tot > $rows) {
    if ($page > 1) {
        $link_prev = Url::Get(array('page' => $page - 1));
    }
    if ($to < $tot) {
        $link_next = Url::Get(array('page' => $page + 1));
    }
}
if ($this->CurrentState() != 'view' && $tot > $rows) {
    echo $tot;
    ?>
개 중 <?php 
    echo $from;
    ?>
-<?php 
    echo $to;
    ?>
&nbsp;
<button <?php 
    echo $link_prev ? '' : 'disabled="disabled"';
    ?>
Beispiel #12
0
 public function Link($name)
 {
     $att = func_get_args();
     include $this->path_controller('link.php');
     if (!$link[$name]) {
         return false;
     }
     return Url::Get($link[$name]['include'], $link[$name]['exclude'], $link[$name]['path']);
 }
Beispiel #13
0
  </div><!-- .blog_right_links -->

  <h2>최근 댓글</h2>
  <div class="blog_right_links">
    <ul>
<?php foreach($comment as $v) {?>
      <li><a href="<?php echo Url::Get(array('wr_no'=>$v['wr_no']))?>"><?php echo strcut_utf8(strip_tags($v['cmt_content']), 50)?></a>
<?php }?>
    </ul>
  </div><!-- .blog_right_links -->

  <h2>최신글</h2>
  <div class="blog_right_links">
<?php echo $latest?>
  </div><!-- .blog_right_links -->

  <h2>태그구름</h2>
  <div class="blog_right_links"><?php echo $tags?></div><!-- .blog_right_links -->

  <h2>게시글 저장소</h2>
  <div class="blog_right_links">
    <ul>
<?php foreach($archive as $k=>$v) {?>
      <li><a href="<?php echo Url::Get(array('archive'=>$k))?>"><?php echo $k?> <span class="cnt">(<?php echo $v?>)</span></a></li>
<?php }?>
    </ul>
  </div><!-- .blog_right_links -->

</div><!-- #blog_right_panel -->
<br clear="all" />
Beispiel #14
0
<!--Start Blogs Container Blogs Container Top-->
<div id="blogs_container_top">
<!--Start Blogs Container Blogs Container Bottom-->
<div id="blogs_container_bottom">

<div style="float:right;margin-right:20px"><?php include $this->path_view('buttons.php');?></div>

<!--Start Breadcrumb-->
<?php echo $breadcrumb?>
<!--End Breadcrumb-->

<!--Start Blog Content-->
<div id="blog_content">

<div class="tag_cloud" style="margin-left:55px;margin-bottom:10px">
  <h1 style="margin-bottom:10px">태그구름</h1>
  <p style="margin-bottom:20px">사용된 모든 태그들을 보여줍니다.</p>
  <div><?php echo $tags?></div>
  <div><a class="button" href="<?php echo Url::Get('',array($this->Config('mode','name'),'ca1','ca2','tag','wr_no'))?>">목록으로 가기</a></div>
</div>

</div><!--End Blog Content-->

<?php include $this->path_view('side.php')?>

</div><!--End Blogs Container Bottom-->
</div><!--End Blogs Container Top-->
</div><!--End Blogs Container-->
</div><!--End Container 5-->

Beispiel #15
0
<?php

if (!defined("__MAGIC__")) {
    exit;
}
$tbn = $this->TBN();
// 테이블명
$clear = $this->Clear();
$r = GV::String('r');
$id1 = GV::String('id1');
$id2 = GV::String('id2');
$clear['bo_admin_path'] = Url::Get(array('r' => $r, 'id1' => $id1, 'id2' => $id2, 'bo_no' => $clear['bo_no'], $this->Mode('name') => 'write'));
$this->Action('insert_record', $clear);
Dialog::Alert("게시판 추가 완료!", $this->Link('list'));
Beispiel #16
0
    'alt'=>'블로그관리'
  );
}

if($_GET['writeMode']!='tagcloud') {
  $btns[] = array(
    'href'=>$this->Link('tagcloud'),
    'icon'=>'btn_tagcloud.gif',
    'alt'=>'태그구름'
  );
}

// 분류나 기타 태그별 보기등이 실행중일 때 전체보기 버튼 생성
if($_GET['writeMode'] || $_GET['wr_no'] || $_GET['ca1'] || $_GET['ca2'] || $_GET['tag']) {
  $btns[] = array(
    'href'=>Url::Get('', array('wr_no','ca1','ca2','tag','writeMode')),
    'icon'=>'btn_list.gif',
    'alt'=>'목록보기'
  );
}

if($this->CurrentState()=='view') {
	if($this->Can('list')) {
		$btns[] = array(
			'href'=>$this->Link('list'),
      'icon'=>'btn_list_search.gif',
			'alt'=>'검색목록'
		);
	}
	if($this->Can('modify')) {
		$btns[] = array(
Beispiel #17
0
<?php if(!defined('__MAGIC__')) exit; ?>

<!-- 비밀번호확인 -->
<form method="post" action="<?php echo Url::Get('', GV::check)?>">

<div id="check_password">
  <div class="icon"><img src="<?php echo $this->path_img('icon_secret.gif')?>" alt="lock"/></div>
  <p>게시물을 수정하려면 비밀번호를 입력하세요.</p>

  <table class="">
    <tbody>
    <tr>
      <th>비밀번호</th>
      <td class="center"><input type="password" name="password" size="8" title="글작성시 입력한<br/>비밀번호를 입력하세요"/></td>
    </tr>
    </tbody>
  </table>

  <input type="image" class="btn_ok" src="<?php echo $this->path_img('btn_ok2.gif')?>" alt="확인"/>
</div>

</form>
Beispiel #18
0
<?php

if (!defined("__MAGIC__")) {
    exit;
}
$state_x = GV::Number('state_x');
$state_o = GV::Number('state_o');
if ($state_o == '' && $state_x == '') {
    Url::Go(Url::Get(array('state_x' => 20)));
}
Beispiel #19
0
    $_list['class'] = 'last';
  }
  $list[] = $_list;
}




$config = Board::Inst()->bo_no($this->bo_no);
?>

<?php if($config->bo_use_category) { ?>
<input type="hidden" name="ca1" value='<?php echo $_GET['ca1']?>'/>
<input type="hidden" name="ca2" value='<?php echo $_GET['ca2']?>'/>
<input type="hidden" name="ca3" value='<?php echo $_GET['ca3']?>'/>
<input type="hidden" name="base_url" value='<?php echo Url::Get('',array('ca1','ca2','ca3'))?>'/>
<input type="hidden" name="bo_category" value='<?php echo $config->bo_category?>'/>
<?php }?>

<!-- total,category -->
<div id="ca_line">
  <div id="category"></div>
  <?php if($this->Config('mb','admin')) {?>
  <a class="btn_admin" href="<?php echo $config->bo_admin_path?>"><img src="<?php echo $this->path_img('btn_admin.gif')?>" alt="admin"/></a>
  <?php }?>
  <div id="total"><img src="<?php echo $this->path_img('total.gif')?>" alt="total"/> Total <?php echo number_format($this->Sql('list_cnt'))?></div>
</div>

<div id="gallery_list">
  <!-- 목록시작:공지 -->
  <?php if(is_array($list_notice) && sizeof($list_notice)!=0) {?>
Beispiel #20
0
</li>
<?php 
    }
    ?>
</ul>
<div style="margin-top:20px"><strong>삭제필드</strong></div>
<ul style="list-style:none">
<?php 
    if (count($check['drop']) == 0) {
        ?>
<li>없습니다</li><?php 
    }
    foreach ($check['drop'] as $v) {
        ?>
<li><?php 
        echo $v;
        ?>
</li>
<?php 
    }
    ?>
</ul>
<?php 
}
?>

<button style="margin-top:20px;" onclick="location.href='<?php 
echo Url::Get(array('install' => 'excute'));
?>
'">설치 및 변경</button>
</div>