te')); return $arr; } /* 遍历用户所有主题 * @param $uid 用户ID * @param int $page 页数 * @param int $pagesize 每页记录条数 * @param bool $desc 排序方式 TRUE降序 FALSE升序 * @param string $key 返回的数组用那一列的值作为 key * @param array $col 查询哪些列 */ function thread_tid_find_by_uid($uid, $page = 1, $pagesize = 1000, $desc = TRUE, $key = 'tid', $col = array()) { if (empty($uid)) return array(); $orderby = TRUE == $desc ? -1 : 1; $arr = thread_tid__find($cond = array('uid' => $uid), array('tid' => $orderby), $page, $pagesize, $key, $col); return $arr; } // 遍历栏目下tid 支持数组 $fid = array(1,2,3) function thread_tid_find_by_fid($fid, $page = 1, $pagesize = 1000, $desc = TRUE) { if (empty($fid)) return array(); $orderby = TRUE == $desc ? -1 : 1; $arr = thread_tid__find($cond = array('fid' => $fid), array('tid' => $orderby), $page, $pagesize, 'tid', array('tid', 'verify_date')); return $arr; } function thread_tid_delete($tid) { if (empty($tid)) return FALSE; $r = thread_tid__delete(array('tid' => $tid)); return $r; } function thread_tid_count() { $n = thread_tid__count(); return $n; } // 统计用户主题数 大数量下严谨使用非主键统计 function thread_uid_count($uid) { $n = thread_tid__count(array('uid' => $uid)); return $n; } // 统计栏目主题数 大数量下严谨使用非主键统计 function thread_fid_count($fid) { $n = thread_tid__count(array('fid' => $fid)); return $n; } ?>javascript - facebook connect blank pop up on chrome - Stack Overflow
最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

javascript - facebook connect blank pop up on chrome - Stack Overflow

programmeradmin2浏览0评论

I'm trying to integrate Facebook Connect to my site using the javsacript SDK.

The codes are like

<script type="text/javascript"> 
    window.fbAsyncInit = function() {
         FB.init({appId: '**********', status: true, cookie: true, xfbml: true});

         /* All the events registered */
         FB.Event.subscribe('auth.login', function(response) {
             // do something with response
             login();
         });
         FB.Event.subscribe('auth.logout', function(response) {
             // do something with response
             logout();
         });

         FB.getLoginStatus(function(response) {
             if (response.session) {
                 // logged in and connected user, someone you know
                 login();
             }
         });

         (function() {
            var e = document.createElement('script');
            e.type = 'text/javascript';
            e.src = document.location.protocol +
                '//connect.facebook/en_US/all.js';
            e.async = true;
            document.getElementById('fb-root').appendChild(e);
        }());
     };
</script>

then the button <fb:login-button autologoutlink="true" perms="email,status_update,publish_stream"></fb:login-button>

This works fine in Firefox; but in chrome, the facebook pop-up to "allow" the app to access fb ends up with a black page title "XD Proxy". Can anyone help me figure it out??

I'm trying to integrate Facebook Connect to my site using the javsacript SDK.

The codes are like

<script type="text/javascript"> 
    window.fbAsyncInit = function() {
         FB.init({appId: '**********', status: true, cookie: true, xfbml: true});

         /* All the events registered */
         FB.Event.subscribe('auth.login', function(response) {
             // do something with response
             login();
         });
         FB.Event.subscribe('auth.logout', function(response) {
             // do something with response
             logout();
         });

         FB.getLoginStatus(function(response) {
             if (response.session) {
                 // logged in and connected user, someone you know
                 login();
             }
         });

         (function() {
            var e = document.createElement('script');
            e.type = 'text/javascript';
            e.src = document.location.protocol +
                '//connect.facebook/en_US/all.js';
            e.async = true;
            document.getElementById('fb-root').appendChild(e);
        }());
     };
</script>

then the button <fb:login-button autologoutlink="true" perms="email,status_update,publish_stream"></fb:login-button>

This works fine in Firefox; but in chrome, the facebook pop-up to "allow" the app to access fb ends up with a black page title "XD Proxy". Can anyone help me figure it out??

Share Improve this question asked May 7, 2011 at 17:57 ptamzzptamzz 9,36531 gold badges94 silver badges151 bronze badges 2
  • open facebook in chrome, logout, try it again – dragonjet Commented May 8, 2011 at 3:58
  • same thing.. still not resolved. :/ – ptamzz Commented May 9, 2011 at 6:24
Add a ment  | 

3 Answers 3

Reset to default 12

I was recently having trouble with a website I was working on and Chrome leaving the Facebook login page open. Title of the popup was "XD Proxy". If I closed the popup manually, I was logged into the site.

I found that the problem occurred when I had the website installed as a Chrome App from the Chrome store. Once I uninstalled the Chrome App, the Facebook login worked perfectly. This just started happening a few weeks ago for me so I went to the Chrome App store to see if I needed to update the app settings. I changed the version number and uploaded a few new images that the Chrome App Store now requires but it did not fix the problem. As soon as I installed the App in Chrome, the Facebook login stopped working again. I uninstalled....works perfectly.

The Chrome App Store lets you package up websites as a hosted app so the only thing you do to get in in the store is upload a manifest file with information about the website and a few images.

To summarize what Doug said, and explain what worked for me:

I had the exact same problem. I also had Facebook installed as a Chrome App. By simply deleting that app, the blank pop-up problem disappeared.

I had the exact same problem as Doug and David. Uninstalling Facebook APP fixed this.

发布评论

评论列表(0)

  1. 暂无评论