Passer la navigation

[Résolu] Responsive grid not functioning properly on tablet and mobile

This support ticket is created Il y a 4 years, 8 months. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Fuseau horaire du supporter : Asia/Karachi (GMT+05:00)

Marqué : 

Ce sujet contient 4 réponses, a 2 voix.

Dernière mise à jour par sharlaC Il y a 4 years, 8 months.

Assisté par: Waqar.

Auteur
Publications
#2170215

Tell us what you are trying to do?
Hi. I have my grid set to two columns on desktop (working as should) and 1 column mobile (also working as should). However, even though I have the grid set to 1 column on tablet, it's showing as two.
lien caché
Also, Even though I have my width set to 100% on both tablet and mobile, it's showing margin on both sides even though the browser inspector says margin is set to 0

Is there any documentation that you are following?
Responsive grids with toolset article

Is there a similar example that we can see?
lien caché
What is the link to your site?
lien caché

#2170617
responsive-web-design-breakpoints.png

Hi,

Thank you for contacting us and I'd be happy to assist.

You'll find the settings for the responsive web design breakpoints at WP Admin -> Toolset -> Settings -> General.
( example screenshot attached )

By default, the breakpoint for the tablets is 781px and for mobiles it is 599px. From your website's code, it seems that the same breakpoints are set on your website too

If you'll check your page on screens wider than 781px (desktops), the grid is showing in two columns, and on screens equal to or lower than 781px ( tablets & mobiles ), the grid is showing in a single column. You're welcome to change these breakpoints as needed.

I'm not sure exactly which margins are you referring to, so you're welcome to share some screenshots.

regards,
Waqar

#2171081
Screen Shot 2021-09-16 at 9.23.23 AM.png
Screen Shot 2021-09-16 at 9.21.15 AM.png

Waqar,
Thanks for giving me that little tip! That worked great.
As far as the margins that I'm talking about...... my container and grids are set to 0px margin and padding, as well as the container set to full width. I want the menu at the top to be stretched across the width of the screen on mobile and tablet with no padding or margin left and right.
Please see the screen shot of the dev site: lien caché
and the screen shot of the live site: lien caché

How can I achieve the same look as the live site?

Thanks,
Deanna

#2171919

Thanks for the update and the screenshots.

The header menu section is actually being controlled by the Divi theme's own styles and not by Toolset plugins.

Using Chrome's inspect element tool ( lien caché ), you'll see that the theme sets the header container area to max-width of 100%, on screens equal to or wider than 981px. And for screens smaller than that, sets the max-width to 1100px and width to 80%.
( screenshot: lien caché )

You can add some custom CSS code in your theme's general custom CSS code, to override that. For example:


@media (max-width: 980px) {
.et_fullwidth_nav #main-header .container {
    width: 95%;
    max-width: 95%;
    padding-right: 0px;
    padding-left: 0px;
}
}

You can read more about CSS media queries at:
lien caché

Note: The custom code examples from our forum are shared to get you started in the right direction. You're welcome to adjust them as needed and for more personalized customization assistance, you can consider hiring a professional from our list of recommended contractors:
https://toolset.com/contractors/

#2174179

My issue is resolved now.. Thanks Waqar! You are a master of your craft.