Site logo

Archived topic

Woocommerce mobile width breakpoint for single product page

8 replies · Started by Sladki dar d.o.o. on October 5, 2020

Viewing posts 1–9 of 9

Hi,

How can I change mobile width breakpoint for single product page? Below is an example of screen copy how single product page looks when I change width of browser window - it looks too "squeezed". I would need to set breakpoint at least 50-100 px sooner...

https://ibb.co/0YKhDCb

Hi,

You can try this PHP snippet.

add_filter('woocommerce_style_smallscreen_breakpoint', function ($px) {
  $px = '767px';
  return $px;
}
);

Just change the "767px" to a value of your preference.

Hi David,

On Appearance > Customize > General, can you try setting the structure to "Flexbox"?

After setting, clear any cache and check the page again.

Let us know how it goes.

Hi Elvin, no joy with that, sorry.

Thanks, I've added that to the child functions.php.
It's OK on a slimmed-down dev site so maybe I have a plugin conflict somewhere.
Dave

I think I've fixed it. The Variation Images plugin was causing it. I no longer need that plugin so it's off and all looks OK.

Yeah - i was just looking and noticed there was a different Gallery coming from that plugin.
Glad to hear you found the solution!

This archived topic is closed to new replies.