views:

71

answers:

2

I was using UIWebview to play a video in portrait mode. It was working fine in case of iphone OS 3.2 . Some times ago i updated my iphone OS to 4.0 then problem came(No video player is coming now). My current build version of application is 3.1.2. Thanks a lot for any kind of help.

A: 

hi! I am not sure if this is an option for you, and you probably know about that. but beginning with iOS 3.2 you can rotate MPMovieController (or MPMovieViewController) without going to fullscreen, and you do not need to use a UIWebView for that.

kind regards,phil.

dreipol
A: 

You need to set the allowsInLineMediaPlayback of a webview to yes. To make your code run across all platforms you could use the following code:

//check if the system os version is higher than 3.2 NSString *os_verson = [[UIDevice currentDevice] systemVersion]; NSLog(os_verson);
if([os_verson localizedCompare:@"3.2"] != NSOrderedAscending) { self.webView.allowsInlineMediaPlayback = YES; }

learner11