따

common.js 에 있는 menu() 함수는 어떤 기능을 가지고 있나요?

common.js 에 있는 menu() 함수는 어떤 기능을 가지고 있나요?    



    var last_id = null;
 
    function menu(id) {
        if (id != last_id) {
            if (last_id != null)
                document.getElementById(last_id).style.display = "none";
           
   document.getElementById(id).style.display = "block";
            last_id = id;
        }
        else {
            document.getElementById(id).style.display = "none";
            last_id = null;
        }
    }




보니까, admin.head.php 에서 호출 되던데요..

function imageview(id, w, h)
{

    menu(id);

    var el_id = document.getElementById(id);
 
    submenu = el_id.style;
    submenu.left = tempX - ( w + 11 );
    submenu.top  = tempY - ( h / 2 );

    selectBoxVisible();

    if (el_id.style.display != 'none')
        selectBoxHidden(id);
}

function help(id, left, top)
{
    menu(id);

    var el_id = document.getElementById(id);

    submenu = el_id.style;
    submenu.left = tempX - 50 + left;
    submenu.top  = tempY + 15 + top;

    selectBoxVisible();

    if (el_id.style.display != 'none')
        selectBoxHidden(id);
}

|

댓글 1개

말풍선 박스 나오는 겁니다.

? 아이콘 누르면 설명 나오는거 있죠..
만약 두개가 나란히 있을때 1? 2? 두개 다 뜨면 곤란하니까 각각의 아이디를 부여해서 하나씩 보이고 감추는 기능입니다.
댓글을 작성하시려면 로그인이 필요합니다.

그누보드4 관련 질문은 QA 로 이전됩니다. QA 그누보드4 바로가기 기존 게시물은 열람만 가능합니다.

+
제목 글쓴이 날짜 조회
10-02-09 조회 1,754
10-02-09 조회 1,652
10-02-09 조회 1,624
10-02-09 조회 1,058
10-02-09 조회 1,067
10-02-09 조회 1,015
10-02-08 조회 1,173
10-02-08 조회 2,797
10-02-08 조회 1,660
10-02-08 조회 1,270
10-02-08 조회 1,395
10-02-08 조회 1,756
10-02-08 조회 1,627
10-02-08 조회 1,099
10-02-08 조회 1,084
10-02-08 조회 1,673
10-02-08 조회 1,326
10-02-08 조회 1,635
10-02-08 조회 2,145
10-02-08 조회 2,016