0 Replies Latest reply on Jan 18, 2014 2:18 PM by vinothini balakrishnan

    Play inline html5 videos in iOS

    vinothini balakrishnan

      I would like to play a html5 video inline (by default it will play fullscreen).

      <video width="320" height="240" controls>
        <source src="http://clips.vorwaerts-gmbh.de/big_buck_bunny.mp4" type="video/mp4" webkit-playsinline>
      </video>
      

       

       

      For that I need to set UIWebview property allowsInlineMediaPlayback = Yes in RhoMobile for iOS app.

       

      Under rhorunner.xcodeproj, I tried to set it at Classes/MainView/SimpleMainView.m

      - (UIWebView*)newWebView:(CGRect)frame {
          UIWebView *w = [[UIWebView alloc] initWithFrame:frame];
          w.scalesPageToFit = YES;
          w.userInteractionEnabled = YES;
          w.multipleTouchEnabled = YES;
          w.clipsToBounds = NO;
          w.dataDetectorTypes = UIDataDetectorTypeNone;
          w.delegate = self;
          w.autoresizesSubviews = YES;
          w.allowsInlineMediaPlayback = YES;
      

       

       

      but its of no use. Video still plays fullscreen.

      Could you please help ?