views:

24

answers:

1

I have webview.

Now I want to add a subview to it. I added it using addsubview method.

The view got added, but did not scrolled with webview.

I want my subview to be scrolled with the webview.

How can I do that?

Regards, Akshay.

A: 

In order to do that, you would need to tinker with the internals of UIWebView and find out it's view hierarchy, so you can add the subview inside the scoller.

It's probably easier to tweak your HTML inside the view, so you can include something similar to your custom view (text or an image) in it.

You can later interact with your "fake view" via Javascript.

pgb
Is it possible if I have a UIWebView object? I have to work with existing webView object and cannot create new one by subclassing..
Akshay Shah