Facebook Tab & App 開發(fā)入門和FAQ
最近在做Facebook Tab & App的開發(fā).
想分享一些基本的文檔和概念給大家;
希望可以幫助大家了解Facebook中一些基本的概念, 資源和初步開發(fā)入門.
Facebook已經(jīng)成為一個(gè)重要的公司宣傳平臺(tái),活動(dòng)和廣告平臺(tái),還有豐富的應(yīng)用和游戲.
Facebook Tab & App Development
- What is Tab
- https://developers.facebook.com/docs/appsonfacebook/pagetabs/
- Maximum width is 520px.
- Tab can add to a Page.
- What is Page
- This is a page sample http://www.facebook.com/Microsoft
- How can I create a page for testing? http://www.facebook.com/pages/create.php
- Publish status of page
- In the top of page, it is not published if you see following information (you should have admin permission)

-
-
- Only Page admin can assess page if it is not published
-
- What is Facebook App
- http://developers.facebook.com/docs/guides/canvas/
- For developer, check this out for more information http://developers.facebook.com/docs/appsonfacebook/tutorial/
- Maximum width is 760px
- Pre-condition (Before Development)
- You are developer in Facebook website
- You are administrator of this tab application
- You are admin of page (if you want to add a tab to a page)
- Usually, all Facebook Tab & Page should support both HTTP & HTTPS
- You have your own website to deploy Tab & Page application
- Create a new tab or application
- Open https://developers.facebook.com/apps
- Click Create New App in the right side

-
- Following 3 tabs are important (configure Site URL to local path, let we can debug in our local environment)

-
- Site URL is the root path of your website (all rest of URL should start with value of Site URL)
- Rest 4 URLs are entry point of Tab & App
- Facebook will call these entry point via HTTP POST with signed_request information
- http://developers.facebook.com/docs/authentication/signed_request/
- Signed_Reuqest include some important information
- Does user like this page or application
- User’s AsseccToken
- Configuration of sandbox
- Settings -> Advanced
- Enable sandbox mode means that only admin can access this Tab & App
FAQ:
- 授權(quán)
- OAuth 2.0
- Basic
- Recommend all page in your website include Facebook script and initialization code
- Recommend we have individual page to handle entry point
- Plugins
- http://developers.facebook.com/docs/plugins/
- Use Fb.Event.subscribe to monitor event (ie: user login)
- http://developers.facebook.com/docs/reference/javascript/FB.Event.subscribe/
- Iframe cannot fire event (please use xfbml)
- Use JavaScript to call FB.ui to fire Plugins
- How can we know if user likes our page or not?
- Get information from signed_request
- How can we remove scroll bar in Tab & Page
- Style in body element : overflow:hidden
- Call FB.Canvas.setSize
- http://developers.facebook.com/docs/reference/javascript/FB.Canvas.setSize/
- How can we grab information from facebook (Graph API & FQL)
- We can get public information from Facebook API
- We have to get AccessToken if we want to access private information
- We can get AccessToken signed_request
- We can get AccessToken from any login page
- from FB.login in javascript
- from login.php
- After we get AccessToken
- http://developers.facebook.com/docs/reference/api/
- If we don’t get enough permission from user, we may not grab information
- Library
希望這些Facebook相關(guān)資料能幫助你對(duì)facebook開發(fā)有一個(gè)大概的概念,
posted on 2011-11-30 10:42 聽(tīng)說(shuō)讀寫 閱讀(1948) 評(píng)論(1) 收藏 舉報(bào)
浙公網(wǎng)安備 33010602011771號(hào)