이윰빌더 갤러리게시판 이미지 클릭시 새창말고 바로 원본사이즈보려고 하는데요

매출이 오르면 내리는 수수료! 지금 수수료센터에서 전자결제(PG)수수료 비교견적 신청해 보세요!
이윰빌더 갤러리게시판 이미지 클릭시 새창말고 바로 원본사이즈보려고 하는데요

QA

이윰빌더 갤러리게시판 이미지 클릭시 새창말고 바로 원본사이즈보려고 하는데요

본문

3667096840_1543039934.117.png

 

지금 위에처럼 이미지를 클릭하면 원본사이즈로보기 나오면서 새창으로 열리는데

클릭하면 바로 그자리에서 볼수 있게하려면 어디를 수정해야 할까요?

이미지는 긴쪽이 1024로 리사이즈해서 올리고 있습니다.

 

 

function close_modal(wr_id) {
    window.parent.closeModal(wr_id);
}

function board_move(href) {
    window.open(href, "boardmove", "left=50, top=50, width=500, height=550, scrollbars=1");
}

$(function() {
    $('.board-view-file-conts img').parent().attr('class', 'view-img-popup').removeAttr('target');
    $('.view-img-popup').each(function() {
        var dataSource = $(this).attr('href');
        $(this).attr('data-source', dataSource);
    });
    $('.board-view-file-conts img').each(function() {
        var imgURL = $(this).attr('src');
        $(this).parent().attr('href', imgURL);
    });
    $('.view-img-popup').magnificPopup({
        type: 'image',
        closeOnContentClick: true,
        mainClass: 'mfp-img-mobile',
        image: {
            verticalFit: true,
            titleSrc: function(item) {
                return '· <a class="image-source-link" href="'+item.el.attr('data-source')+'" target="_blank">원본 이미지 보기</a>';
            }
        }
    });

    if($('.board-view-con img').parent().hasClass('view_image')) {
        $('.board-view-con img').parent().attr('class', 'view-image-popup').removeAttr('target');
        $('.view-image-popup').each(function() {
            var dataSource = $(this).attr('href');
            $(this).attr('data-source', dataSource);
        });
        $('.board-view-con img').each(function() {
            var imgURL = $(this).attr('src');
            $(this).parent().attr('href', imgURL);
        });
        $('.view-image-popup').magnificPopup({
            type: 'image',
            closeOnContentClick: true,
            mainClass: 'mfp-img-mobile',
            image: {
                verticalFit: true,
                titleSrc: function(item) {
                    return '· <a class="image-source-link" href="'+item.el.attr('data-source')+'" target="_blank">원본 이미지 보기</a>';
                }
            }
        });
    } else {
        $('.board-view-con img').wrap('<a class="view-image-popup">');
        $('.board-view-con img').each(function() {
            var imgURL = $(this).attr('src');
            $(this).parent().attr('href', imgURL);
        });
        $('.view-image-popup').magnificPopup({
            type: 'image',
            closeOnContentClick: true,
            mainClass: 'mfp-img-mobile',
            image: {
                verticalFit: true
            }
        });
    }

    // 이미지 리사이즈
    $(".board-view-atc").viewimageresize();
 

 

이 질문에 댓글 쓰기 :

답변 1

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

회원로그인

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