Authentication Facebook Iframe应用程序-奇怪的重定向问题
当我在FacebookIframe应用程序中执行服务器端重定向时,我会看到这个奇怪的带有链接的Facebook徽标。当我单击它时,我会被重定向到我首先设置重定向的站点。这里发生了什么?有没有点击保护 谢谢 重定向代码: 尝试客户端重定向 两种情况下的结果相同Authentication Facebook Iframe应用程序-奇怪的重定向问题,authentication,facebook,iframe,Authentication,Facebook,Iframe,当我在FacebookIframe应用程序中执行服务器端重定向时,我会看到这个奇怪的带有链接的Facebook徽标。当我单击它时,我会被重定向到我首先设置重定向的站点。这里发生了什么?有没有点击保护 谢谢 重定向代码: 尝试客户端重定向 两种情况下的结果相同 啊!Facebook有如此糟糕的文档,我在为它开发的过程中遇到了无数的问题 这是因为你不能直接从应用重定向。使用href链接并将目标属性指定为_top或使用javascript window.top.location="redirectu
啊!Facebook有如此糟糕的文档,我在为它开发的过程中遇到了无数的问题 这是因为你不能直接从应用重定向。使用href链接并将目标属性指定为_top或使用javascript
window.top.location="redirecturl"
要解决此错误。为了重定向,请使用以下代码:
<html><head>
<script type="text/javascript">
window.top.location.href = "<?php echo $loginUrl; ?>";
</script>
<noscript>
<meta http-equiv="refresh" content="0;url=<?php echo $loginUrl; ?>" />
<meta http-equiv="window-target" content="_top" />
</noscript>
您要重定向到的URL是什么?@serg555,如您所见。。。已经试过了!:/@Henrik那么,当您执行js重定向时,您的页面url在浏览器中是什么样子的?客户端和服务器两种方法的结果截图相同。
window.top.location="redirecturl"
<html><head>
<script type="text/javascript">
window.top.location.href = "<?php echo $loginUrl; ?>";
</script>
<noscript>
<meta http-equiv="refresh" content="0;url=<?php echo $loginUrl; ?>" />
<meta http-equiv="window-target" content="_top" />
</noscript>