• cheonmu

    (@cheonmu)


    ?????,

    ?? ??? ???? ?????? ?? ?????.

    ????? ???? ??????, ???? ??? ?? ????? ??? ???? ???? ??? ?? ????.

    ???? ???? ???? ??, ??? ?? iframe? ???? ???? ?? ?? ??? ??? ?????.

    ??? ?? ??? ?? ?? ?? ??? ??? ???????..

    ??? ??? ???? ???? ??

    ?????

    Uncaught TypeError: Cannot read properties of null (reading ‘style’) ??? ????? ??,

    echo? ?? wrap? ??? ???? ??? ??, ????? fomr-checkout.php ??? div? ?? ???????… ??? ??? ???? ??

    ?? ??? ????, ???? ???? ??? ??? ??? ?? ? ?????

    ?????.

    <?php
    add_action('woocommerce_after_order_notes', 'customise_checkout_field');
      
    function customise_checkout_field()
    {
    
        echo '<div id="wrap" style="display:none;border:1px solid;width:500px;height:300px;margin:5px 0;position:relative">
    <img src="//t1.daumcdn.net/postcode/resource/images/close.png" id="btnFoldWrap" style="cursor:pointer;position:absolute;right:0px;top:-1px;z-index:1" onclick="foldDaumPostcode()" alt="?? ??">
    </div>';
    }
    
    ?>
    
        <script type="text/javascript">
    	
        var element_wrap = document.getElementById('wrap');
    
        function foldDaumPostcode() {
            // iframe? ?? element? ???? ??.
            element_wrap.style.display = 'none';
        }
    
            function billingPostcodeSearch() {        
                new daum.Postcode({
                    oncomplete: function(data) {
                        document.getElementById('billing_postcode').value = data.zonecode;
                        document.getElementById('billing_address_1').value = data.address;
                        document.getElementById('billing_address_2').focus();
    
    			element_wrap.style.display = 'none';
    
    			document.body.scrollTop = currentScroll;
    		
                    },
                onresize : function(size) {
                    element_wrap.style.height = size.height+'px';
                },
                width : '100%',
                height : '100%'
    				
                }).embed(element_layer);
    
    			        element_layer.style.display = 'block';
    
            }
    		
    		
    		
    		
            function shippingPostcodeSearch() {        
                new daum.Postcode({
                    oncomplete: function(data) {
                        document.getElementById('shipping_postcode').value = data.zonecode;
                        document.getElementById('shipping_address_1').value = data.address;
                        document.getElementById('shipping_address_2').focus();
                    }
                }).open();
            }
        </script>
    
    • This topic was modified 3 years ago by cheonmu.
    • This topic was modified 3 years ago by cheonmu.
  • The topic ‘??? ?? ?? ???? ??? ?? ?????’ is closed to new replies.