我是 Facebook 应用程序的新手。我在 IE 上运行此应用程序时遇到问题。
登录后它重定向到搜索操作 (zend-framework),然后当我单击按钮时重定向另一个操作以及相同的操作。它破坏 session 。
<script type="text/javascript">
window.fbAsyncInit = function() {
FB.init({
appId : '<?php echo $this->appid ?>',
status : true, // check login status
cookie : true, // enable cookies to allow the server to access the session
xfbml : true // parse XFBML
});
FB.Canvas.setSize({width: 760, height: 980});
};
(function() {
var e = document.createElement('script');
e.src = document.location.protocol +
'//connect.facebook.net/en_US/all.js';e.async = true;
document.getElementById('fb-root').appendChild(e);
}());
</script>
HTML代码
<div class="cross">
<a href="<?php echo $this->url(array('controller' => 'index', 'action' =>'search','cancel'=>'c'),'default',true) ?>">
</a>
</div>
请帮帮我。 感谢考虑。
最佳答案
在您的 Controller 中,尝试将其添加到您的 init() 函数中。
$this->getResponse()->setHeader('P3P', 'CP="NOI ADM DEV PSAi COM NAV OUR OTRo STP IND DEM"');
这是 IE 的一个已知问题
关于Facebook 应用程序无法在 IE 中正常运行,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6304901/