/home/mjc1/public_html/html/millennium/web_manual/left_navi.inc.php


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103

<style>
.tit_blue{color: #1A558C !important;}
.manual_cate_tit{font-size: 24px;font-weight: 800;line-height: 50px;margin-bottom: 20px;}

.cate_first{width: 250px;cursor: pointer;}
.cate_tit_first{width: 100%;height: 44px;display: block;line-height: 44px;}
.cate_tit_first span{font-size: 18px;font-weight: 600;color: #5797D2 !important;}
.cate_tit_second{width: 100%;height: 42px;display: block;line-height: 42px;font-size: 15px;font-weight: 600;color: #343434 !important;padding-left: 20px !important; cursor:pointer;box-sizing: border-box;}
.cate_tit_third{width: 100%;height: 32px;display: block;line-height: 32px;font-size: 14px;font-weight: 600;color: #6D6D6D !important;padding-left: 30px !important;box-sizing: border-box;cursor: pointer;}
.cate_tit_third:hover{color: #343434 !important;}

/* .cate_second{display: none;} */
.cate_third{display: none;background: #f5f5f5;}

.hover-underline-animation2 {display: inline-block;position: relative;}
.hover-underline-animation2::after {content: '';position: absolute;width: 100%;transform: scaleX(0);height: 2px;bottom: 0;left: 0;background-color: #1A558C;transform-origin: bottom right;transition: transform 0.25s ease-out; margin-bottom:2px;}
.hover-underline-animation2:hover::after {transform: scaleX(1);transform-origin: bottom left;}
</style>

<div>
    <h3 class="tit_blue manual_cate_tit"><a href="./index.php" class="tit_blue">À¥ ¸Å´º¾ó ¸ñÂ÷</a></h3>
    <div id="cate_menu_div"><!--Ä«Å×°í¸® ¸Þ´º ¿µ¿ª-->
        <?php
            $cat1_sql 
"SELECT * FROM mBoard_menual_cate1 AS a ORDER BY idx ASC";
            
$cat1_res mysql_query($cat1_sql,$connect_web);
            while(
$cat1_info mysql_fetch_array($cat1_res)) {
        
?>
        <ul class="cate_first">
            <li>
                <a class="cate_tit_first ">
                    <span class="hover-underline-animation2 " style="position: relative;">
                    <?php echo $cat1_info['name']; ?>
                    <img src="../img/web_manual/icon_manual_body.png" alt="Ç¥½Ã" style="margin-top: -3px;margin-left: 6px;width: 16px;transform: rotate(90deg);">
                    </span>
                </a><!--// 1Â÷ Å±״ aűנȰ¼ºÈ­ ¾øÀ½-->
                <?php
                    $cat2_sql 
"SELECT * FROM mBoard_menual_cate2 AS a WHERE a.pidx = '{$cat1_info[idx]}' ORDER BY idx ASC";
                    
$cat2_res mysql_query($cat2_sql,$connect_web);
                    while(
$cat2_info mysql_fetch_array($cat2_res)) {
                        
                        
$cat3_sql "SELECT * FROM mBoard_menual_cate3 AS a WHERE a.pidx = '{$cat2_info[idx]}' ORDER BY idx ASC";
                        
$cat3_res mysql_query($cat3_sql,$connect_web);
                        
$cnt mysql_num_rows($cat3_res);

                        if(
$cnt 0) { $href ""; } else { $href "href='./func_detail.php?c2=".$cat2_info['idx']."'"; }
                
?>
                <ul class="cate_second" style="display:none;">
                    <li>
                        <a <?php echo $href?>" class="cate_tit_second"><?php echo $cat2_info['name']; ?></a><!--// 2Â÷ Å±״ aűנȰ¼ºÈ­ ¾ø´Â °æ¿ì, Àִ °æ¿ì ±¸ºÐ-->
                        <ul class="cate_third">
                            <?php while($cat3_info mysql_fetch_array($cat3_res)) { ?>
                            <li><a href="./func_detail.php?c3=<?php echo $cat3_info['idx']; ?>" class="cate_tit_third"><?php echo $cat3_info['name']; ?></a></li><!--// 3Â÷ Å±״ aűנÇ×»ó È°¼ºÈ­ ±¸ºÐ-->
                            <?php ?>
                        </ul>
                    </li>
                </ul>
                <?php ?>
            </li>
        </ul>
        <?php ?>
    </div><!--//Ä«Å×°í¸® ¸Þ´º ¿µ¿ª-->
</div>

<script>
$(function(){

    $('.cate_tit_first').click(function(){ //1Â÷ Ä«Å×°í¸® Å¬¸¯ÇÒ °æ¿ì
        var cate_sec = $(this).closest('li').find('.cate_second');

        if(cate_sec.css('display') == "none"){ //2Â÷ Ä«Å×°í¸®°¡ ¾È ¿­·ÁÀִ °æ¿ì, 2Â÷ Ä«Å×°í¸® ¿­±â
            cate_sec.css('display','block');
            $(this).children('span').children('img').css('transform','rotate(-90deg)');
        } else {
            cate_sec.css('display','none');
            $(this).children('span').children('img').css('transform','rotate(90deg)');
        }
    });

    $('.cate_second').each(function(){ //3Â÷ Ä«Å×°í¸®¸¦ °¡Áø 2Â÷Ä«Å×°í¸® µû·Î Ç¥½Ã
        var cate_third_count = $(this).find('.cate_third li').length;
        if(cate_third_count > 0){
            $(this).find('.cate_tit_second').append('<img src="../img/web_manual/icon_manual_body.png" alt="Ç¥½Ã" style="margin-top: -3px;margin-left: 6px;width: 16px;transform: rotate(90deg);">');
        }
    });

    $('.cate_tit_second').click(function(){ //2Â÷ Ä«Å×°í¸® Å¬¸¯½Ã 3Â÷Ä«Å×°í¸® È°¼ºÈ­ ¿©ºÎ
        var cate_third = $(this).closest('li').find('.cate_third');

        if(cate_third.css('display') == "none"){ //3Â÷ Ä«Å×°í¸®°¡ ¾È ¿­·ÁÀִ °æ¿ì
            cate_third.css('display','block');
            $(this).children('img').css('transform','rotate(-90deg)');

        } else {
            cate_third.css('display','none');
            $(this).children('img').css('transform','rotate(90deg)');
        }
    });

    

});
</script>