UIViewController *webViewController = [[[UIViewController alloc] init] autorelease];
UIWebView *uiWebView = [[[UIWebView alloc] initWithFrame: CGRectMake(0,0,320,480)] autorelease];
[webViewController.view addSubview: uiWebView];
[self.navigationController pushViewController:webViewController animated:YES];
i want to allow orintation change to this web view. how to achieve this?
also , if i navigate from previous view which is landscape, web view gives blank space on right. please help to fix this also.
The default implementation of
-[UIViewController shouldAutorotateToInterfaceOrientation :]returnsYESfor portrait orientation only. For other orientations, it returnsNO.You must create a subclass of
UIViewController. In your subclass, you must overrideshouldAutorotateToInterfaceOrientation:to returnYESfor all the orientations you want to support. Use an instance of your subclass instead of using a basicUIViewController.