홈빌드


● 마이홈 접속자 확인 하기




컨텐츠 정보


본문

마이홈 접속자 확인 하기

3232235521_1646149515.936.png

▶ 적용소스는 사용주인 테마에 적용

<!-- W:wwwtheme11qkr_BS4-Basic_v5416sideside-basic.php -->

 <!-- W:wwwtheme11qkr_BS4-Basic_v5416sideside-index.php -->



<hr class="hr" />
<div class="widget-box">
    <ul style="padding:0; margin:0; list-style:none;">
        <h6>
            <li>
                <!-- W:wwwtheme11qkr_BS4-Basic_v5416sideside-basic.php -->
                <!-- W:wwwtheme11qkr_BS4-Basic_v5416sideside-index.php -->
                <i class="fa fa-bug red"></i>
                <!-- <a href="<?php echo $at_href['connect']; ?>"> -->
                <a href="<?php echo G5_BBS_URL ?>/current_connect.php">
                    현재 접속자♨
                    <span class="pull-right"><?php echo number_format($stats['now_total']); ?><?php echo ($stats['now_mb'] > 0) ? '(<b>' . number_format($stats['now_mb']) . '</b>)' : ''; ?>
                        명</span></a>
            </li>
            <li>
                <i class="fa fa-bug"></i>
                오늘 가입자※
                <span class="pull-right"><?php echo number_format($today_mem[cnt]); ?>
                    명</span>
            </li>
            <li>
                <i class="fa fa-bug"></i>
                어제 가입자※
                <span class="pull-right"><?php echo number_format($yesterday_mem[cnt]); ?>
                    명</span>
            </li>
            <li>
                <i class="fa fa-bug"></i>
                주간 가입자※
                <span class="pull-right"><?php echo number_format($week_mem[cnt]); ?>
                    명</span>
            </li>
            <li>
                <i class="fa fa-bug"></i>
                오늘 방문자
                <span class="pull-right"><?php echo number_format($stats['visit_today']); ?>
                    명</span>
            </li>
            <li>
                <i class="fa fa-bug"></i>
                어제 방문자
                <span class="pull-right"><?php echo number_format($stats['visit_yesterday']); ?>
                    명</span>
            </li>
            <li>
                <i class="fa fa-bug"></i>
                최대 방문자
                <span class="pull-right"><?php echo number_format($stats['visit_max']); ?>
                    명</span>
            </li>
            <li>
                <i class="fa fa-bug"></i>
                전체 방문자
                <span class="pull-right"><?php echo number_format($stats['visit_total']); ?>
                    명</span>
            </li>
            <li>
                <i class="fa fa-bug"></i>
                전체 게시물※
                <span class="pull-right"><?php echo number_format($total_cnt); ?>
                    개</span>
            </li>
            <li>
                <i class="fa fa-bug"></i>
                전체 댓글수※
                <span class="pull-right"><?php echo number_format($total_cnt2); ?>
                    개</span>
            </li>
            <li>
                <i class="fa fa-bug"></i>
                전체 회원수
                <span class="pull-right at-tip" data-original-title="<nobr>오늘 <?php echo $stats['join_today']; ?> 명 / 어제 <?php echo $stats['join_yesterday']; ?> 명</nobr>" data-toggle="tooltip" data-placement="top" data-html="true"><?php echo number_format($stats['join_total']); ?>
                    명</span>
            </li>
        </h6>
    </ul>
</div>
<!-- ============================================= -->

3232235521_1646149806.7946.png

상기소스는  상단에  아래  관련 소스가  먼저 추가 되어야 합니다.

<?php
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가 
		//W:wwwtheme11q.kr_NB-Basiclayoutsideside-basicside.php
	// 총게시물수
	$write_total = sql_fetch(" select sum(bo_count_write) as sum_count_write from {$g5['board_table']} ");
	$total_cnt = $write_total['sum_count_write'];
	// 총코멘트수
	$comment_total = sql_fetch(" select sum(bo_count_comment) as sum_count_comment from {$g5['board_table']} ");
	$total_cnt2 = $comment_total['sum_count_comment'];
// =============================
//W:wwwtheme11q.kr_NB-Basiclayoutsideside-basicside.php
// 총게시물수
// $write_total = sql_fetch(" select sum(bo_count_write) as sum_count_write from {$g5['board_table']} ");
// $count_write = $write_total['sum_count_write'];
// 총코멘트수
// $comment_total = sql_fetch(" select sum(bo_count_comment) as sum_count_comment from {$g5['board_table']} ");
// $count_comment = $comment_total['sum_count_comment'];
// 아미나 정의가  실행 않됨
// 총게시물수
$write_total = sql_fetch(" select sum(bo_count_write) as sum_count_write from {$g5['board_table']} ");
$total_cnt = $write_total['sum_count_write'];
// 총코멘트수
$comment_total = sql_fetch(" select sum(bo_count_comment) as sum_count_comment from {$g5['board_table']} ");
$total_cnt2 = $comment_total['sum_count_comment'];
// 오늘가입자
$today = G5_TIME_YMD;
$today_mem = sql_fetch(" select count(*) as cnt from {$g5['member_table']} where  LEFT(mb_datetime, 10)='$today' ");
// $today = date('Y-m-d',strtotime("-1 days"));
// $today_mem =sql_fetch("select count(*) as cnt  from {$g5['member_table']} where LEFT(mb_datetime, 10)='$today' ");
// 어제가입자
$yesterday = date('Y-m-d', strtotime("-2 days"));
$yesterday_mem = sql_fetch("select count(*) as cnt  from {$g5['member_table']} where mb_datetime between '$yesterday'  and '$today' ");
// week 가입자
$week = date('Y-m-d', strtotime("-7 days"));
$week_mem = sql_fetch(" select count(*) as cnt from {$g5['member_table']} where mb_datetime between '$week'  and '$today' ");
// ============================ 추가
// 페이지에서는 사이드 메뉴 출력
echo na_widget('sidemenu');
?>




☞ https://11q.kr 에 등록된 자료 입니다. ♠ 정보찾아 공유 드리며 출처는 링크 참조 바랍니다♠1.png
뷰PDF add1,add2



관련자료

댓글 0
등록된 댓글이 없습니다.



♥간단_메모글♥


최근글


새댓글



PHP 안에 HTML ☞ 홈페이지 화면갱신 시간은 ♨
▶ 2024-05-03 19:25:20

오늘의 홈 현황


  • 현재 접속자♨ 283 명
  • 오늘 가입자※ 3 명
  • 어제 가입자※ 3 명
  • 주간 가입자※ 15 명
  • 오늘 방문자 1,588 명
  • 어제 방문자 1,869 명
  • 최대 방문자 13,042 명
  • 전체 방문자 4,301,345 명
  • 전체 게시물※ 8,551 개
  • 전체 댓글수※ 24,552 개
  • 전체 회원수 10,948 명

QR코드


☞ QR코드 스캔은 kakao앱 자체 QR코드

알림 0








최신글↑