Posted - 11/08/2022 : 09:46:06
So I added a flashing lightbar Image to my index.php page for the holiday season approaching and just was wondering if I did things reasonably correct. You can view it at http://www.cop-cars.com The lightbar .gif image dimensions are 298 x 16. I am definitely an amateur when it comes to css coding, but here's what I came up with.
I added the following to style.css:
.holidaylights { background-image: url('../images/lightswhite.gif'); background-repeat: repeat-x; overflow: hidden; text-align:left; max-width:1140px; position:relative;} .holidaylights img { max-width:100%}
I put the following in my index.php:
<div class="holidaylights"> <img src="../images/lightswhite.gif" alt=""/> </div>
It seems to be working, but on a mobile device, it doesn't expand like the other responsive image do when I turn the device sideways.
Just looking to get an opinion on my css coding from a professional.
Thanks
Eric Payne
|