Hi,
I have a video that is playing if i click a button in my site but when page load (first page in my site) it is not playing!
urls.py
urlpatterns = [
path('', views.firstpage, name="first-page"),
views.py
def firstpage(request):
return render(request,'firstpage.html',{})
firstpage.html
<video autoplay loop>
<source src="{% static 'cart/slider/sale.mp4' %}" type="video/mp4">
</video>
when i go to the site the video is there but it is not playing. if you open the video in other tab or page it will play. Also i have a button in my page called “Announcements” if clicked it will go to the page “firstpage.html” and the video will autoplay!
take a look at my site:
My site