kome
kome

Reputation: 51

Play video on laravel blade

Trying to use the video player on the page.

    <video  src="{{URL::asset("/images/upload/$itemContent->file_name")}}" controls>
    </video>

The link is correct (the file is available in the source code of the page). In the case of mp4 only audio.

Upvotes: 5

Views: 23314

Answers (1)

lufc
lufc

Reputation: 2040

<video width="320" height="240" controls>
      <source src="{{URL::asset("/images/upload/$itemContent->file_name")}}" type="video/mp4">
    Your browser does not support the video tag.
</video>

https://www.w3schools.com/html/html5_video.asp

Upvotes: 6

Related Questions