image doesnt fill width of screen

  • This topic has 2 replies, 2 voices, and was last updated 5 years, 1 month ago by Dax. This post has been viewed 902 times
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #10039354
    Dax
    Participant

    Hi, can you check this on your iphone or android phone

    in the WHO WE ARE section near the top of the website, if you view this section on say a normal windows PC, it shows 3 images

    BUT the problem is, if you view this section on a mobile phone, it only shows a single image and its not aligned correctly (its aligned left which doesn’t look nice)

    can you tell me why this is?


    #10039355
    Support
    Keymaster

    Hello,

    1) Change the HTML to:

    <div class="col-sm-8 col-md-6 col-lg-4 offset-sm-4 offset-md-4 offset-lg-2 position-relative mt-sm-5 custom-imgs-position" style="top: 1.7rem;">
    	<img src="img/generic/street-lighting3.jpg" class="img-fluid position-absolute custom-imgs-position-1 appear-animation" data-appear-animation="expandIn" data-appear-animation-delay="300" style="top: 10%; left: -50%;" alt=""/>
    	<img src="img/generic/street-lighting2.jpg" class="img-fluid position-absolute custom-imgs-position-2 appear-animation" data-appear-animation="expandIn" style="top: -33%; left: -29%;" alt=""/>
    	<img src="img/generic/street-lighting1.jpg" class="img-fluid position-relative custom-imgs-position-3 appear-animation mb-2" data-appear-animation="expandIn" data-appear-animation-delay="600" alt=""/>
    </div>

    2) Add this css:
    (css/custom.css)

    @media (max-width: 991px) {
    	.custom-imgs-position .custom-imgs-position-1,
    	.custom-imgs-position .custom-imgs-position-2,
    	.custom-imgs-position .custom-imgs-position-3	{
    		position: static !important;
    		left: 0 !important;
    		top: 0 !important;
    		display: block;
    		margin: 15px auto;		
    	}
    }

    Regards.


    #10039360
    Dax
    Participant

    thank you


Viewing 3 posts - 1 through 3 (of 3 total)

This topic is marked as "RESOLVED" and can not rceive new replies.