Home › Forums › CSS › Random hover on page load › Reply To: Random hover on page load
November 29, 2017 at 1:33 pm
#263111
Beverleyh
Participant
Just rename your image files to 1.jpg, 2.jpg, 3.jpg, etc. and use the reduced img markup and CSS provided in your php web page. The paragraphs in the top 2 lines are just a description and standalone demo to explain/show what’s going on, and are not necessary for the functionality of the sample.
The script is randomly writing a number from 1-5 into the markup as the img src filename. If you view the source of the page or inspect it in the dev console, you’ll be able to see what’s happening.