iframe 응용 프로그램에 심각한 문제가 있습니다. 많은 외부 JS 라이브러리 및 기타 동적 stuuf 사용해야하므로 FMBL 응용 프로그램을 수행 할 수 없습니다. require_login()을 호출하면 응용 프로그램이 아직 설치되지 않았을 때 대화 상자를 설치하는 응용 프로그램이 표시됩니다. 그런 다음 인증 응용 프로그램이 auth_token과 같은 매개 변수가있는 끝없는 리디렉션 루프에 들어가면 설치됩니다. 어제는이 문제를 해결할 수 있었지만 오늘은 다시 깨졌습니다 ... FB로 무슨 일이 벌어지고 있습니까? 그것은 해결책을 찾기 위해 나를 미치게 만들었습니다. 그물에서 발견 된 것들은 아무 것도 작동하지 않는 것 같습니다.iFrame의 Facebook require_login() 앱
는 지금까지 시도 :
이http://abhirama.wordpress.com/2010/03/07/facebook-iframe-xfbml-app/ 위의
http://www.markdeepwell.com/2010/02/validating-a-facebook-session-within-an-iframe/ http://forum.developers.facebook.com/viewtopic.php?pid=210449 http://www.ajaxlines.com/ajax/stuff/article/facebook_fbml_rendering_in_iframe_application.php http://www.aratide.com/php/solving-the-break-out-issue-in-iframe-facebook-applications/
아무도 일하지 (! 2010년 3월 7일) http://forum.developers.facebook.com/viewtopic.php?pid=156092 http://www.keywordintellect.com/facebook-development/how-to-set-up-a-facebook-iframe-application-in-php-in-5-minutes/
... 사람들에 따르면, 일부 FB 문서 : http://wiki.developers.facebook.com/index.php/Cross_Domain_Communication_Channel내 예를 들어, 테스트 파일가 다음과 같이보고 :
<?php
//Link in library.
require_once '../application/vendor/Facebook/facebook.php';
//Authentication Keys
$appapikey = 'XXXX';
$appsecret = 'XXXX';
//Construct the class
$facebook = new Facebook($appapikey, $appsecret);
//Require login
$user_id = $facebook->require_login();
?>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:fb="http://www.facebook.com/2008/fbml">
<head>
<title></title>
</head>
<body>
<script src="http://static.ak.facebook.com/js/api_lib/v0.4/FeatureLoader.js.php" type="text/javascript"></script>
This is you: <fb:name uid="<?php echo $user_id?>"></fb:name>
<?php var_dump($facebook->$this->facebook->api_client->friends_get())?>
<script type="text/javascript">
FB_RequireFeatures(["XFBML"], function(){
FB.Facebook.init("<?=$appapikey?>", "xd_receiver.html");
});
</script>
</body>
</html>
그리고 크로스 도메인 파일 xd_receiver.html입니다 : 제대로 작동
<!doctype html public "-//w3c//dtd xhtml 1.0 strict//en" "http://www.w3.org/tr/xhtml1/dtd/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head>
<title>cross-domain receiver page</title>
</head>
<body>
<script src="http://static.ak.facebook.com/js/api_lib/v0.4/XdCommReceiver.js" type="text/javascript"></script>
</body>
</html>
어떻게받을 수 있나요?
나는 이것을하기 위해 Kohana 프레임 워크를 사용하고 있으며 이미 facebook PHP 라이브러리의 url :: redirect()로 header ('Location')를 대체했습니다.
iframe 응용 프로그램입니다.나는 iframe 내부에서 require_login을 호출하려고 시도하고, 페이스 북 외부에서 내 애플리케이션의 URI로 auth_token 변수로 무한 루프로 끝나는 내 애플리케이션으로 리디렉션된다. 나는 FBML 응용 프로그램을 만들려고했는데을 사용하여 캔버스에 iframe을 넣으려고했지만 흐름은 동일합니다. –