The Web Design Group

... Making the Web accessible to all.

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Playing movie in pop-up lightbox
Blueie
post Jan 7 2019, 10:58 PM
Post #1





Group: Members
Posts: 4
Joined: 15-September 13
Member No.: 19,734



Hello

I have the following code in a Web page that, once a thumbnail (thumb-1.jpg in my case) is clicked, it displays a larger image, violin.jpg, in a lightbox pop-up. The same applies to my second thumbnail, thumb-2, which displays jump.jpg in a lightbox:

CODE
<a href="images/violin.jpg" data-lightbox="violin"><img class="example-image" src="images/thumb-1.jpg" alt="violin" data-title="My caption" /></a>
    
<a href="images/jump.jpg" data-lightbox="jump"><img class="example-image" src="images/thumb-2.jpg" alt="jump" data-title="My caption" /></a>


Please see attachments.

I would like the user to still click on the thumbnails but, instead of the lightbox displaying a larger image of the thumbnail, for it to display a
movie file (MP4). Would that be possible?

Thanks.


Attached thumbnail(s)
Attached Image Attached Image
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Christian J
post Jan 9 2019, 05:38 AM
Post #2


.
********

Group: WDG Moderators
Posts: 9,630
Joined: 10-August 06
Member No.: 7



That should be possible, if the user's browser supports playing mp4 files directly (my browsers do, but they may or may not display a run/download prompt first), and if the Lightbox script can display .mp4 files (test it, and/or check the documentation!).

Another idea is to make Lightbox create HTML5 VIDEO elements to display the mp4 files in, but that might require some rewriting.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post

Reply to this topicStart new topic
2 User(s) are reading this topic (2 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 28th March 2024 - 10:05 AM