Home > DeveloperSection > Forums > Increase Font size in UIWebView in iOS
Chris S
Chris S

Total Post:48

Posted on    November-15-2015 11:21 PM

 iPhone iPhone  Ios  Objective C 

 1 Reply(s)
 347  View(s)
Rate this:

I have created an app using UIWebView, it works perfectly.

But now I have a problem to increase Font size in UIWebView.
Can anyone help tell me, how can I do this?

Tarun Kumar

Total Post:210

Posted on    November-17-2015 11:04 PM

You can use this code:

NSString*myString = @"Hello...";
int textFontSize=5;
NSString*myStr = [NSString stringWithFormat:@"<html><body><script>var str='%@';
                  [myWebView loadHTMLString:myHTML baseURL:nil];

I hope this code is helpful for you.

Don't want to miss updates? Please click the below button!

Follow MindStick