• I have a few issues that I am trying to resolve. (Storefront (child theme deli) My WordPress, Woocommerce, and all plugins are updated as i see they need to be updated.

    1st- I have 6 Main categories and only 3 of them are showing on my homepage. I have checked everything and by all accounts, they should be showing.

    2nd- This is a redesign of my old site were i used storefront boutique I am in the process of retaking pictures to the correct parameters so they should show up correctly but I think that is not the issue. Reason being as all of the pictures on my shop page have been fixed and they are still staggered. I have used a snippet that should get them to be unstaggered but it hasn’t worked. They are supposed to be 4 or 5 across but they are only 3 to 4 across.
    Not all of the pictures have been retaken on sub categories or reordered into their sub-categories but they are still off as well.

    If you can give me any suggestions on why this is still happening I would be grateful.

Viewing 9 replies - 1 through 9 (of 9 total)
  • Thread Starter Christine Miller

    (@christinemiller)

    1. Please post the shortcode that you’re using. Highlight it and use the editor’s code tag. Ensure the categories which don’t display have got something in them.

    2. You’ll need to fix the number of items you want per row. Currently your site is set for 5 items per row. That’s why there is a new line after every 5th item. If you want, you can change it to 4 with a snippet from here:
    https://docs.woocommerce.com/document/change-number-of-products-per-row/

    When you’ve settled on the number per row, the item width and/or the margin can be reduced using custom css. Please come back when you have fixed the number per row.

    Thread Starter Christine Miller

    (@christinemiller)

    All categories are showing on the categories page as i have something added to them it’s on the homepage that they are missing from I have 6 categories and only 3 are showing. Here is the home page and the category page and you will see what i mean.Look down at the very bottom of the page
    homepage – https://stormshadowsjewelry.com/

    2. you misunderstood me I want it to show 5 columns consistently and it is not showing them consistently it is showing 4 on one line 3 on another 2 on another etc and staggering back and forth see this page.

    https://stormshadowsjewelry.com/product-category/earrings/chain-maille-earrings/

    Plus they aren’t even in line with each other.
    It even does that on the category page itself when it should be showing an even number items in each column it isn’t

    This is the snippet i am using i have no clue where i got it from i think it was from woo commerce before they decided that they wouldn’t help nonpaying customers even though it was their own product. I don’t know what you mean by highlight it i am a bit out of my zone with code. is why i use a snippet editor etc.

    —————————-

    add_filter( ‘loop_shop_per_page’, create_function( ‘$cols’, ‘return 30;’ ), 20 );

    —————————

    The “code” button is in the row of buttons just above the box where you type these posts. It makes code easier to read and preserves formatting. However, I don’t think your using a shortcode to display the categories, I think you’re using the Storefront Homepage Control plugin? This plugin shows 3 categories by default. You can change this number with this code:

    add_filter( 'storefront_product_categories_args', 'custom_homepage_category_columns' );
    function custom_homepage_category_columns( $args ) {
      $args['limit'] = 6;
      $args['columns'] = 6;
      return $args;
    }

    It worked for me using the “My Custom Functions” plugin, but you can try your snippet editor.

    To show 5 items in a line on shop and category pages, you need to reduce the size of the items and the margin between them. To do so, try this custom css:

    @media screen and (min-width: 768px) {
      .page-template-template-fullwidth-php .site-main .columns-4 ul.products li.product,
      .page-template-template-homepage-php .site-main .columns-4 ul.products li.product,
      .storefront-full-width-content .site-main .columns-4 ul.products li.product {
        width: 18%;
        margin-right: 2.5%;
      }
    }

    Custom css can be entered at:
    Dashboard > Appearance > Customise > Additional CSS

    Feel free to tweak the % values a bit to suit your taste. If you make them a bit big, the 5th item will spill over into the next row.

    Regarding the add_filter() snippet, it uses the create_function() function which is deprecated, ie it should no longer be used.

    Thread Starter Christine Miller

    (@christinemiller)

    Thank you so much for fixing things on my page. Wish i had you on call if I needed you, your my best-est friend.

    Thread Starter Christine Miller

    (@christinemiller)

    wonder if you got a fix for something else the product on the home page don’t seem centered to me could be because i have 4 each of them and 6 of the categories down below.

    Thread Starter Christine Miller

    (@christinemiller)

    and how to remove the related products from the bottom of each of my products searched but can’t find a way. I have certain products i want to show on those but they aren’t showing because the related products are there instead.

    Yes, there’re not centred because there are 4 and you’ve standardised on 5 per row. Either add a fifth or set up your your site for 4 per row.

    The remove_action() line to remove the related products is here:
    https://docs.woocommerce.com/document/remove-related-posts-output/

    Thread Starter Christine Miller

    (@christinemiller)

    thanks for the fix for related however, i have more than 4 featured set up and only 4 are still showing in the we recommend section I know this as i took out one and another that i did have popped up in its place so something is keeping either the 5th picture from popping up.

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Couple of Issues’ is closed to new replies.