1

How do you set the minimum height for an app in facebook? Do I need to modify the viewport ?

Here is my current viewport info:

<meta name="viewport" content="initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
Paul
  • 11,671
  • 32
  • 91
  • 143

1 Answers1

3

The default height can be set through your app dashboard (on the Facebook Developers website); setting it to 'fluid' should allow you to resize it on the fly.

I'd suggest using CSS to control the height (either of the canvas, or a containing div) in different circumstances, though from a user's perspective it would be better if you could keep the canvas height consistent throughout your app...

MassivePenguin
  • 3,701
  • 4
  • 24
  • 46
  • You can set the height of the iframe through the Facebook Developers website. That sets the maximum height you have available to you. The minimum height is controlled via CSS within your app itself. Please don't mark my answer down if you haven't taken the time to read (and understand) it properly. – MassivePenguin Jan 28 '13 at 09:05
  • i read it and you're saying you can set minimum height but it's not working penguin, because when you call autoGrow function it's also shrinks page... – Ömer Faruk AK Jan 28 '13 at 10:45
  • Since my original answer was written (almost a year and a half ago) Facebook's AutoGrow function has changed slightly. Have you looked at solutions like this: http://stackoverflow.com/questions/9197411/facebook-iframe-fb-canvas-setautogrow-does-not-auto-grow-after-initial-load ? – MassivePenguin Jan 28 '13 at 12:26
  • i resolved this problem by defining a new div and giving it a min-height attribute. so if you may improve your answer, i can remove my down vote :) – Ömer Faruk AK Jan 31 '13 at 21:25