Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added a troubleshooting guide #3814

Merged
merged 4 commits into from Dec 2, 2016
Merged

Added a troubleshooting guide #3814

merged 4 commits into from Dec 2, 2016

Conversation

brandonocasey
Copy link
Contributor

@brandonocasey brandonocasey commented Nov 30, 2016

Description

Added a troubleshooting guide

Requirements Checklist

  • Feature implemented / Bug fixed
  • If necessary, more likely in a feature request than a bug fix
    • Docs/guides updated
  • Reviewed by Two Core Contributors

Copy link
Member

@misteroneill misteroneill left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Two small comments, looks good otherwise.

nor adaptive streaming is a consideration, MP4 is a good choice.

#### I need adaptive streaming or live streaming
Use HLS with [videojs-contrib-hls]()https://github.com/videojs/videojs-contrib-dash or
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Link is outside parentheses and links to -dash instead of -hls. 😄

* If you are using HLS or DASH your server must implement CORS headers if the video is served from a different domain than your page. This is also true for text tracks such as captions.

## Problems with Fullscreen
* If your player is in an iframe, make sure it and any parent iframes have the fullscreen attributes allowfullscreen webkitallowfullscreen mozallowfullscreen. Without these, the browser will not allow fullscreen mode.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should probably use ` here to call out the attribute names.

## Problems with media formats
Make sure you are using formats that video.js can play:
* Does your browser/OS support the type of video that you are trying to play?
* Do you have a plugin that will add support for that video format?
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be clear that we're talking about video.js plugins and not the likes of Flash.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe link to videojs-contrib-hls/dash and videojs-youtube as non-exhaustive examples.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

video or audio format

Make sure you are using formats that video.js can play:
* Does your browser/OS support the type of video that you are trying to play?
* Do you have a plugin that will add support for that video format?
* Verify that you are using the correct mime-type/content-type for your videos. This used to determine if video.js can play a video.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you are specifying the correct media type for your source, whether you are using the <source> element or the src() API method.

Maybe link to http://www.iana.org/assignments/media-types/media-types.xhtml#video ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seems like a good idea will do!

* Some low end phones save video in 3GP format but give it an MP4 extension. These files will not play.


Make sure that Flash is installed and that the Flash tech is included with video.js:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This reads as Flash is required. "If you are using Flash videos, ..."

HLS is more convenient as mobile browsers have native support.

## Problems when hosting video
* Your server must support byte-range requests as Chrome and Safari rely on it. Most servers support this by default, but we have seen many issues with PHP as it does not support byte-range by default.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd leave out the part after the comma as the next bullet addresses PHP

## Problems when hosting video
* Your server must support byte-range requests as Chrome and Safari rely on it. Most servers support this by default, but we have seen many issues with PHP as it does not support byte-range by default.
* If you are proxying the media files via a server side script (PHP), this script must implement ranges. The impact of not doing this ranges from seeking being broken to no playback at all (on iOS).
* Your server must return the correct mime-type/content-type for the video formats.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the correct media type in the Content-type header for the video or audio format being sent

* Your server must support byte-range requests as Chrome and Safari rely on it. Most servers support this by default, but we have seen many issues with PHP as it does not support byte-range by default.
* If you are proxying the media files via a server side script (PHP), this script must implement ranges. The impact of not doing this ranges from seeking being broken to no playback at all (on iOS).
* Your server must return the correct mime-type/content-type for the video formats.
* If you are using HLS or DASH your server must implement CORS headers if the video is served from a different domain than your page. This is also true for text tracks such as captions.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Link to enablecors.org

* Do you have a video.js plugin that will add support for a media format to video.js? For Example:
* [videojs-contrib-hls][hls]
* [videojs-contrib-dash][dash]
* [videojs-contrib-youtube][youtube]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's just videojs-youtube.


### If you are using Flash videos:
* Make sure that Flash is installed
* Make sure the Flash tech is included with video.js (in video.js it won't be, see [videojs-flash][flash])
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This isn't true right now

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ahh meant to type in video.js >= v6.0.0. Good catch

@gkatsev gkatsev merged commit 54ff1f9 into videojs:master Dec 2, 2016
@brandonocasey brandonocasey deleted the chore/troubleshooting branch December 6, 2016 16:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants