Search code examples
iosvideoyoutubewistia

wistia in native iOS player?


could someone please tell me whether it is possible to embed vistia in the native iOS video player ? We are looking for alternative options to hosting videos on youtube, and have heard some good things about vistia. Currently our app play a youtube url directly within the native video player. Thanks in advance.


Solution

  • Well I guess the native player doesn't want to play with that url.

    I would imagine that UIWebView should open that url anyway.

    Here is how you would use it:

    - (void)loadRequestFromString:(NSString*)urlString
    {
        NSURL *url = [NSURL URLWithString:urlString];
        NSURLRequest *urlRequest = [NSURLRequest requestWithURL:url];
        [self.webView loadRequest:urlRequest];
    }
    

    And then when you would load the view that has the UIWebView in it just call that method. In your case

    [self loadRequestFromString:@"http://fast.wistia.net/embed/iframe/5gu0g6pvgu"];