Skip to content Skip to sidebar Skip to footer

Initializing Iscroll With Phonegap And JQuery Mobile

I have built a project using phonegap and jquery mobile, and have iscroll working perfectly on the first page. However on my second page iscroll isn't running. Can someone tell me

Solution 1:

I never used phonegap, but im building a JQM-webapp as well, so i hope this works for you.

iScroll seems to cause several problems trying to implement it in JQM. This is why they came up with jquery.mobile.iscrollview which bascically adapts the iScroll javascript to the jQuery Mobile environment.

Just include the script and add data-iscroll="" to your div. And include all of your scripts in the given order.


Solution 2:

checkDOMChanges: set to false to prevent auto refresh on DOM changes. If you switch off this feature you have to call iScroll.refresh() function programmatically every time the DOM gets modified. If your code makes many subsequent DOM modifications it is suggested to set checkDOMChanges to false and to refresh the iScroll only once (ie: when all changes have been done). Default true.

see more on there page:http://cubiq.org/iscroll


Post a Comment for "Initializing Iscroll With Phonegap And JQuery Mobile"