I am having problem that I am developing a facebook app using iframe, the problem that is coming is that my full content is not being displayed . When I inspect it through firebug then I came to know that iframe is having height: 800px so I want to increase it or set height dynamically. I have tried FB.Canvas.setSize() but it didn't work so what should I do?
Full height of Facebook app Canvas in iframe
20.3k views Asked by Hafiz At
2
There are 2 answers
1
Alsemany
On
just go to your application settings change to auto resize
and use the function FB.Canvas.setAutoResize
as this code
<div id="fb-root"></div>
<script src="http://connect.facebook.net/en_US/all.js"></script>
<script>
FB.init({
appId : 'your APP ID Goes Here',
status : true, // check login status
cookie : true, // enable cookies to allow the server to access the session
xfbml : true// parse XFBML
});
FB.Canvas.setAutoResize(7);
</script>
<?php
for($i=1;$i<100;$i++)
{
echo "$i<br>";
}
?>
this will make 99 lines with autoresize
Related Questions in FACEBOOK
- Facebook Post Images from local system on own Page
- Provide an archipelago name that humans cannot utter
- How can I look this email address
- Not getting all leads from Meta/Facebook using webhook for page leadgens
- Unsupported post request when trying to create a custom audience via the endpoint https://graph.facebook.com/lapi-version), (custom-audience-id/users)
- Java resized JPEG seems to be invalid format for Facebook?
- How to implement facebook pixel in flutter in 2024 any example?
- Need WhatsApp Data Backup from Api
- Facebook login via JS-SDK via OAuth will get stuck half-way
- Short time token with the Graph API and Facebook login through the iOS SDK
- Facing the "Messaging may be unavailable" error - WhatsApp Cloud API
- Facebook Graph API - Story endpoint does not return all active stories
- Javascript / Dynamically append text element above embedded facebook posts
- When I post text with media on Facebook, the text does not show
- How to search a list of groups using facebook APIs
Related Questions in FACEBOOK-GRAPH-API
- Facebook Post Images from local system on own Page
- How can I get posts from a facebook page using the graph API?
- Not getting all leads from Meta/Facebook using webhook for page leadgens
- Unsupported post request when trying to create a custom audience via the endpoint https://graph.facebook.com/lapi-version), (custom-audience-id/users)
- Page access token
- Facebook login via JS-SDK via OAuth will get stuck half-way
- Python - Facebook Check For Duplicate Post Before Posting
- Facebook Graph API - Story endpoint does not return all active stories
- Can't set permissions in Graph API Explorer tool
- My Authentication is not working in published mode
- Can I get my comment's reactions in FB Graph API Explorer
- Facebook GraphAPI: page subscribed_apps with subscribed_fields messages is not working
- Get Ad Account Billing Payment Transactions
- How to get a person’s username by his ID without a request to the graph?
- I am having trouble understanding the docs for Facebook Login SDK
Related Questions in FACEBOOK-IFRAME
- How is facebook setting its cross-domain datr cookie from an iframe?
- Embed a url in angular
- Facebook embedded Reel?
- Facebook page embedding not working for iFrames in any browser
- I'm loading a angular app uplaoded on firebase in facebook webview. Getting refused to frame error
- Facebook post embed not scrollable
- How to apply iframe video link on website?
- Facebook like button iframe appears very small on react-native webview
- Facebook iframe page plugin doesn't work with "." (dot)
- How can I limit the number of posts that load in the Facebook Page Plugin?
- Embed dozens of comments from Facebook's iframes on a website
- Weird iframe width bug on facebook embed code
- How to fix facebook sharer button that appears cutted on wordpress
- Facebook page iFrame display problem in Boostrap Template while using Laravel as backend to send iframe code
- IE11 ignores X-Frame-Options after redirect
Related Questions in FACEBOOK-JAVASCRIPT-SDK
- Facebook Post Images from local system on own Page
- Facebook login via JS-SDK via OAuth will get stuck half-way
- My Authentication is not working in published mode
- How to provide "Login Using Facebook" for external users when using "Facebook Login For Business" product?
- Facebook Login issue using web SDK
- Getting 'Minified invariant #21945;' error when implementing `Facebook Login for Business` using User Access Token
- Blank screen appearing rather than popup when trying to use Facebook login in my Vite React app
- When running ads on facebook for a web app, does using the facebook sdk help in any way?
- Unable to get custom label from page conversations api
- Facebook's Send to Messenger Plugin Not Working on In-App Browser
- Facebook business sdk giving "error_user_msg": "A tracking pixel is required for ads in a campaign with conversions as its objective.",
- Is there a way to change the version of Facebook Javascript SDK - Instagram Graph API
- How to post local images to Facebook via JavaScript SDK (v19.0)?
- How to post local images to Facebook via JavaScript SDK without URL?
- Configure facebook login button for Business not allowed to add config_id
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
In the developer app on Facebook go to the app and edit settings. In the Facebook integration section you can set "IFrame size" to auto-resize. Then in your app, call FB.Canvas.setAutoResize after FB.init and the canvas should resize itself to fit your content automatically.