cloudinary-video-player icon indicating copy to clipboard operation
cloudinary-video-player copied to clipboard

404 because of Seek thumbnails option

Open time2funk opened this issue 4 years ago • 1 comments

It seems that seekThumbnails option forces player to make GET request (with the wrong URL) to get captions for image sprite preview. It builds the URL itself depending on the video file name and its path. As a result, I get a 404 error because the URL for the captions is wrong.

I see two requests (getting captions) in the networking:

  1. Correct URL

method GET status 200 type vtt URL https://OWN_CLOUDINARY_HOST/.../videos/CAPTIONS_NAME.vtt

  1. Wrong URL

method GET status 404 type gif URL https://res.cloudinary.com/PROJECT_NAME/video/upload/fl_sprite/v1/videos/VIDEO_NAME.vtt

video URL: https://res.cloudinary.com/PROJECT_NAME/video/upload/v1/videos/VIDEO_NAME.mp4

time2funk avatar Nov 10 '21 14:11 time2funk

You can specify the URL for the vtt file in source options. For example, applying VTT to CC and subtitles using JavaScript:

player.source(
      'my-video',
      {
        textTracks: {
          captions: {
            label: 'English captions',
            language: 'en',
            default: true,
            url: 'https://res.cloudinary.com/cloudinary-training/raw/upload/my-captions.vtt'
          },
          subtitles: [
            {
              label: 'English subtitles',
              language: 'en',
              url: 'https://res.cloudinary.com/cloudinary-training/raw/upload/my-captions.vtt'
            }
          ]
        }
      });

Did you specify your VTT in this way? Can you share your code?

rebeccapeltz avatar Nov 10 '21 17:11 rebeccapeltz