The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums JavaScript Pass the mouse over the image and get a video

  • This topic is empty.
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
  • #190151

    I’m tried to show a video when you pass the mouse over a image but i failed so many times, i got the code form this page ( and i tried to modify but there is no result for me.

    I use this video ( that is from the “gfy” page that converts gifs into videos and load very fast. This is the code:

    <video id=”gfyVid1″ class=”gfyVid” width=”646″ height=”326″ autoplay=”” loop=”” muted=”muted” style=”display: block;”>

            <source id="webmsource" src="//" type="video/webm">
            <source id="mp4source" src="//" type="video/mp4">

    if you can help me i will be very grateful because i don’t have much experience on javascript and css… and sorry for my english… Thank you for reading.


    A demo in Codepen would be useful.


    Ok Paulie_D, this is what i have:

    I want that when you pass the mouse over the players face you can get the video instead of the picture 1, 2 or 3.


    Thank you for answer me, i know how to put the gifs, the problem is that are so slow to load that is a problem for my page, the video is the fastest thing that i can find to put… you know some example that i can use for that script? is very complicated?…


    Thank you so much, you are a really good person!!!

Viewing 5 posts - 1 through 5 (of 5 total)
  • The forum ‘JavaScript’ is closed to new topics and replies.