Jump to content

Image resizing from desktop to mobile on Prestashop 8


Recommended Posts

Hello fellow geeks, what is the best approach to have a nice looking image on a CMS yet when preview from mobile to resize properly. I can do width: 100% which will look great on desktop yet it would look bad on mobile. There has to be a better image mobile-desktop relationship.

cheers,

AJ

Link to comment
Share on other sites

Hi,

if you are referring to the issue of distortion on the mobile view, then you can add 'img-fluid' class to the images.
<img src="path/to/your/image.jpg" class="img-fluid" alt="Responsive Image">

It is a Bootstrap's responsive image class that scales images with their parent containers.

If you have any concerns related to the image responsiveness, then please let us know.

Regards.

Link to comment
Share on other sites

Is magic kid, it works like a charm, so simple yet so effective. I always thought about this issue, you want nice images for the CMS yet you also want the same quality non distorted for the mobile version and class="img-fluid" does just that.

Thanks again!

  • Thanks 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...