-2

Just wondering if anyone can tell me hy this is happening. When I play the video I can hear the audio but the video doesn't show. Heres my code, im a beginner

<video id = "videoplayer" width ="480" height = "270" poster = "../images/video.jpg" controls>
            <source src = "../media/overwatch.mp4">
        <video>
Jacob
  • 91
  • 1
  • 2
  • 7
  • I tried that code and it works as is. Must be something wrong with your video – Asons Apr 17 '17 at 00:04
  • code looks fine, suggest that the encoding isn't supported. try re-encoding using something like ffmpeg and parameters like https://stackoverflow.com/questions/43367937/ffmpeg-resize-video-not-working-in-browser-or-ios/43374801#43374801 – Offbeatmammal Apr 17 '17 at 06:35

1 Answers1

0

Try to use this default snippet - I think you missed the type of the video and check the src!

For more info read this.

<video width="320" height="240" controls>
  <source src="movie.mp4" type="video/mp4">
  <source src="movie.ogg" type="video/ogg">
  Your browser does not support the video tag.
</video>
Felix Haeberle
  • 1,530
  • 12
  • 19