Reputation: 1003
I have a single view appication where I am trying to load jQuery Demos from this site:
http://jquerymobile.com/demos/1.0rc2/ on a UIWebView. But when I click on a component from the demo, I can see a white screen flickers for few milli seconds and only it happens in portrait mode (for landscape it does not appear so). I have spent almost an entire day digging into this, yet no success. I have already posted this query to jQuery mobile forum but have not got any reply yet.
I'm not sure whether it's a bug in UIWebView or in jQuery site.
any help is truly appreciated.
Upvotes: 1
Views: 999
Reputation: 1003
Finally fixed the issue, it's something with CSS for webkit. For this you need to call stringByEvaluatingJavaScriptFromString
on your UIWebview object and pass the parameter which is something like this:
[yourwebviewObject stringByEvaluatingJavaScriptFromString:@"$(document).ready(function(){" "$('head').append('.ui-page {" "-webkit-backface-visibility: hidden;" "}')" "});"];
Hope it will help out there someone.
Upvotes: 3