Play video on laravel blade

13,444
<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

Share:
13,444

Related videos on Youtube

kome
Author by

kome

Updated on June 04, 2022

Comments

  • kome
    kome almost 2 years

    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.

    • akaincore
      akaincore over 5 years
      you are incorrect added video sources. try <video controls> <source src="{{$url}}" type="video/mp4(or whatever you need)"></video>