Search code examples
ioscordovaphonegap-buildoverscroll

Phonegap Build - DisallowOverscroll not working on IOS


I'm having some issues with Phonegap Build and my Iphone.

At the moment I have the following preferences in my config.xml

<preference name="webviewbounce" value="false" />
<preference name="DisallowOverscroll" value="true" />
<preference name="UIWebViewBounce" value="false" />

and the following meta tag;

<meta name="viewport" content="user-scalable=no, initial-scale=1, maximum-scale=1, minimum-scale=1, width=device-width, height=device-height, target-densitydpi=medium-dpi" />

The application compiles fine and my app runs off the 'Test flight' system very well, barring this one issue. The application seems to be 'Draggable' (which I believe is the bounce problem).

Things i've tried;

Delete my Phonegap Build Project.

Remove all config.xml files barring my main one located in the project root.

Using only one of the preferences etc.

Does anyone have any idea how I can prevent the app from being dragged down the screen (I have elements that have overflow on them, and they scroll fine, but the whole app scrolls some times which really effects the user experience).

Thanks.

*Edit 1

So i've opened up my .ipa file on a mac and it seems that in the config.xml the "DisallowOverscroll" is being set to false. I'm not quite sure why this would be happening?


Solution

  • Okay, So I figured it out, thanks to dsokurenko who put the idea in my head that the config.xml wasn't actually being read!

    So my steps to fix this;

    • Create a new phonegap project

    • Copy my files across

    • Move config.xml to /www/ folder (I believe this was the key to fix the issue, change any config values that have /www/ in them

    • Create new app on Phonegap Build, re-build and install!

    This worked for me and I hope it helps someone else.