Tagged: category, column, woocommerce
-
AuthorPosts
-
May 9, 2018 at 11:10 am #953809
Hi
When I set the column count to 5 in my site, only 4 columns are displayed. When I set it to 4, only three columns are displayed. In both cases, the product are aligned to the left, leaving a wide gap on the right side of the page. I want to have 4 columns that stretch across the whole page. I don’t know what I’ve done wrong. Any ideas?Also, I don’t want to show the large category image at the top of the category pages. How can I hide this?
May 9, 2018 at 11:53 am #953839This reply has been marked as private.May 10, 2018 at 1:28 pm #954537Hi stevegjacobs,
There was not enough space in the parent container to have 5 products, and so the width of a product has to be adjusted.
Here is the code you can put in Enfold > General Styling > Quick Css, if it does not work, put into themes/enfold/css/custom.css.shop_columns_5 .products .product { width: 18.2%; }
I do not see any category image on that page. Did you manage to hide it?
If you need further assistance please let us know.
Best regards,
VictoriaJune 1, 2018 at 11:39 pm #965600I have a similar but slightly different issue, I don’t know if its appropriate to ask it here or if I should open a new thread, but here goes…
I’m using shortcode to display a product category within a page. I changed the default 4 columns to 3 like this:
[product_category category=”optional-services” columns=”3″ class=”opt-prod-table”]
But while I do see 3 product columns, there remains a large empty space on the right. Seems like that is the product category container or something. I tried centering and removing margins and padding every way I could think of (including using that CSS Class opt-prod-table that I added) to no avail. It seems that this category shortcode works normally for most users, without the annoying space on the right so I’m thinking it may in some way not be playing nicely with my Enfold theme (which is up to date as is my wordpress, php, plugins etc.)
I’ve included a link to my site where this is happening. Any chance this can be fixed somehow?
June 2, 2018 at 12:51 pm #965840Hi,
Please try the following in Quick CSS under Enfold->General Styling:
ul.columns-3 div .products .product { width: 32% !important; }
Best regards,
RikardJune 2, 2018 at 7:37 pm #965944Thanks a lot for your reply Rikard. Your name makes me think of Game of Thrones :-) Unfortunately the CSS you suggest does not seem to result in any changes to the product category section in question. Any other suggestions what I can try to get these columns and products to behave?
- This reply was modified 6 years, 6 months ago by nextlevelbros.
June 3, 2018 at 7:24 am #966064Hi,
Thanks for the feedback :-)
Please try this instead:
ul.products.columns-3 .product { width: 32% !important; }
Best regards,
RikardJune 3, 2018 at 11:47 am #966105Thanks Rikard, this is a lot better, as the products do appear centered which is a certainly step in the right direction. But this also has the side effect of making the thumbnails a lot bigger than before, which is not something I would choose for. If anything I wish they where smaller than the default size – my products are services, the image thumbnail has no reason to be larger than absolutely necessary. If there is a way to get them centered without enlarging the thumbnails, that would be the perfect solution for me here.
June 4, 2018 at 5:43 am #966303Hi,
Please try this instead:
ul.products.columns-3 .product { margin: 0 13% 5% 0 !important; }
Best regards,
RikardJune 4, 2018 at 4:15 pm #966593Hi Rikard, thanks again for your efforts to help me solve this. That’s an interesting approach but unfortunately its not really working. The products remain left-aligned as a whole, and no matter what percentage of margins I enter, the product/columns either remain unbalanced (extending more to the left side of the screen, never centered in the middle) or wrap to the next line (so I end up with 2 products per column) without ever achieving a center-balanced layout, but also this approach even if it can be made to work, changes the balance and aesthetic of the page, in a way I am not happy with. Truth is, I have already tried all these suggestions we have talked about so far before even writing here.
What I really am trying to achieve is actually quite simple in principle. I want to display the product category as is. Not larger thumbnails, not different margins with more spacing here and there, just what already exists > but centered like the rest of the website. It cannot be that this is the only part of the website that strangely hangs to the left and I also don’t want to change the whole aesthetic (margins, thumbnails sizes) to something inconsistent with the rest of the site just to center this products category section.
If its not possible, I understand, in that case I will look to move to another theme that supports Woocommece without extensive custom work. If it is possible, well it would be great to figure out how.
- This reply was modified 6 years, 6 months ago by nextlevelbros.
June 5, 2018 at 6:56 am #966989Hi,
Please try this instead:
ul.products.columns-3 { display: table; margin: 0 auto; } ul.products.columns-3 .product { width: 32.5% !important; }
If that is not what you are looking for then post a screenshot of your wishes.
Best regards,
RikardJune 5, 2018 at 5:49 pm #967336This is perfect Rikard, exactly what I was talking trying to achieve. I was not familiar with the working of “display: table” and would never have come up with that myself. Very good to know! Thanks for putting up with my very specific desires for the layout of this page and coming through with a solution. I was afraid it would require more extensive tweaking but your latest code is just what the doctor ordered. I’m very pleased to tick this of my to-do list, now on to the next challenge :-)
June 6, 2018 at 12:44 pm #967812Hi,
Great, glad we could help :-)
Please let us know if you should need any further help on the topic or if we can close it.
Best regards,
RikardJune 6, 2018 at 4:52 pm #967942Feel free to close the topic, no further assistance required on this issue on my part. Cheers!
June 7, 2018 at 10:03 am #968357 -
AuthorPosts
- You must be logged in to reply to this topic.