Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Mockup & CodeGen, iPhone & iPad
($9.99)

Make your own iPhone apps
and run them live!
(free)

Manu
($0.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum > iPhone SDK Development Forums > iPhone SDK Development

Reply
 
LinkBack Thread Tools Display Modes
Old 01-29-2009, 01:24 AM   #1 (permalink)
Registered Member
 
Join Date: Dec 2008
Location: Colombo, Sri Lanka
Posts: 58
Send a message via Yahoo to tharindufit Send a message via Skype™ to tharindufit
Default How UIWebView supports scaling

I have a UIWebView in my application and I load a html string to that page and display, but it does not scale properly as when I load a web page from URL, How to enable scaling of my local html page.does it require to be a complex large html page. I have set the setScalesPageToFit to YES.
Code:
NSString *htmlText = "<html><script type="text/javascript" src=""></script><head><title>Tharindu</title>...............</html>";
[webView loadHTMLWithString: htmlText baseURL:nil];
[webView setScalesPageToFit:YES];
tharindufit is offline   Reply With Quote
Old 01-29-2009, 10:29 PM   #2 (permalink)
Registered Member
 
Join Date: Dec 2008
Location: Colombo, Sri Lanka
Posts: 58
Send a message via Yahoo to tharindufit Send a message via Skype™ to tharindufit
Default

Inorder to focus you have to insert not noly a simple html page, but also with in a table, but how do we focus to a specific area with in my web view, I just want to display some percentage of my web page focussed, can we do it with web view
tharindufit is offline   Reply With Quote
Old 02-01-2009, 01:31 PM   #3 (permalink)
FlipConversionDesign
 
Join Date: Aug 2008
Location: Orangeville, Ontario
Posts: 83
Send a message via MSN to flipconversion
Default

bump for answer
flipconversion is offline   Reply With Quote
Old 02-12-2009, 10:50 PM   #4 (permalink)
Registered Member
 
Join Date: Oct 2008
Posts: 54
Default

Try adding this to the header of the HTML:

<meta name="viewport" content="width=320; initial-scale=1.0; maximum-scale=2.0; user-scalable=1;"/>
EPage_Ed is offline   Reply With Quote
Reply

Bookmarks

Tags
fit, html, scale, uiwebview, url

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Advertisements
» Stats
Members: 158,884
Threads: 89,229
Posts: 380,763
Top Poster: BrianSlick (7,129)
Welcome to our newest member, karlam963
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 02:13 PM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0