2012-04-12 4 views
0

타임 라인 업데이트 이후로 내 크기 조정 스크립트가 Facebook에서 작동하지 않습니다. 이 내 코드입니다 :타임 라인 업데이트 이후 Iframe의 크기가 더 이상 조정되지 않음

CSS : 바닥 글에서

<div id="fb-root"></div> 
<script type="text/javascript" src="https://connect.facebook.net/en_US/all.js"></script> 

: 몸에서

html { 

margin:0; 
padding:0; 
height:1500px; 
} 

body { 
width:520px; 
padding:0; 
margin:0; 
height:1500px; 
font-family:Arial, Helvetica, sans-serif; 
font-size:12px; 
color:#555859; 
} 

응용 프로그램에서

<script type="text/javascript"> 
FB.Canvas.setSize({ width: 520, height: 1500 }); 
window.fbAsyncInit = function() { 
FB.Canvas.setAutoGrow(); 
} 
</script> 

, 내가 설정 한을 캔버스 높이가 유동적입니다.

중요한 것을 잃어 버렸습니까? 더 좋은 방법이 있습니까?

답변

1

은 다음과 같이 코드를 수정하십시오 :

window.fbAsyncInit = function() { 
    FB._https = (window.location.protocol == "https:");    
    FB.init({ 
     appId : 'YOUR_APP_ID', 
     status : true, 
     cookie : true, 
     xfbml : true 
    }); 
    FB.Canvas.setAutoGrow(); 

} 
+0

덕분에 많은 동료를! – samn

관련 문제