Difference between revisions of "Titanium webview"

From John Freier
Jump to: navigation, search
(Created page with ' == Setting the height == For IOS setting the height of a WebView can be tough. A good trick is to get the height of the HTML document and setting the WebView height. var ac…')
 
Line 1: Line 1:
 
 
== Setting the height ==
 
== Setting the height ==
 +
 +
'''IOS'''
  
 
For IOS setting the height of a WebView can be tough.  A good trick is to get the height of the HTML document and setting the WebView height.
 
For IOS setting the height of a WebView can be tough.  A good trick is to get the height of the HTML document and setting the WebView height.

Revision as of 16:38, 9 January 2014

Setting the height

IOS

For IOS setting the height of a WebView can be tough. A good trick is to get the height of the HTML document and setting the WebView height.

 var actualHeight = e.source.evalJS("document.body.offsetHeight");
 e.source.height = actualHeight;