Home › Forums › Themes Support › Claue › Categories menu add to sticky menu
- This topic has 12 replies, 2 voices, and was last updated 6 years, 5 months ago by Harry.
-
AuthorPosts
-
-
July 15, 2018 at 11:59 pm #22782
-
July 16, 2018 at 4:08 pm #22800
Hi,
It now have only way to move shop categories to header and display on all pages not only on shop page.
Please copy code to claue-child > views > header > layout-x.php as header layout on your site
<?php if ( is_active_sidebar( 'wc-categories' ) ) : ?> <div class="shop-top-sidebar"> <?php if ( ! function_exists( 'dynamic_sidebar' ) || ! dynamic_sidebar( 'wc-categories' ) ) : endif; ?> </div> <?php endif; ?>
and copy file archive-product.php to claue-child > woocommerce
and remove code on this file
`
`
Best regards
Harry
Premium Wordpress themes and plugins, Best WooCommerce theme https://themeforest.net/user/janstudio/portfolio?ref=janstudio -
July 16, 2018 at 8:33 pm #22826
Hi, so I have added the code to claue-child > views > header > layout-3.php and now see 2 lines of categories but both disappear when scroll.
But I can not find the code you said in woocommerce/templates/archive-product.php
-
July 17, 2018 at 1:07 am #22840
Hi,
1. Please move the code follow this screen shot https://monosnap.com/file/mLvPcHr00HxZeJhztiZMTbRv2Uo4jI
2. Sorry the code in archive-product.php same the code you added in header
<?php if ( is_active_sidebar( 'wc-categories' ) ) : ?> <div class="shop-top-sidebar"> <?php if ( ! function_exists( 'dynamic_sidebar' ) || ! dynamic_sidebar( 'wc-categories' ) ) : endif; ?> </div> <?php endif; ?>
Please delete this code.
Best regards
Harry
Premium Wordpress themes and plugins, Best WooCommerce theme https://themeforest.net/user/janstudio/portfolio?ref=janstudio -
July 17, 2018 at 3:47 am #22851
Hi, sorry I attach archive-product file, it doesn’t have this code I think maybe it comes from below. I tried to comment do action, but it still all looks the same
/**
* Hook: woocommerce_sidebar.
*
* @hooked woocommerce_get_sidebar – 10
*/
/*do_action( ‘woocommerce_sidebar’ );*/Attachments:
You must be logged in to view attached files. -
July 17, 2018 at 4:27 pm #22876
Hi Mag,
The code from line 69 to line 73 in archive-product.php
Best regards
Harry
Premium Wordpress themes and plugins, Best WooCommerce theme https://themeforest.net/user/janstudio/portfolio?ref=janstudio-
July 18, 2018 at 4:36 am #22911
The code from line 69 to line 73 in archive-product.php
sorry I don’t understand what you mean 69-73 code in in archive-product.php is below, do I need to comment it?
*/
do_action( ‘woocommerce_shop_loop’ );wc_get_template_part( ‘content’, ‘product’ );
}
-
-
July 18, 2018 at 7:53 pm #22928
Did you change file archive-product.php
The original code is http://take.ms/t4sXd
Please download attach file for original code
Attachments:
You must be logged in to view attached files.Harry
Premium Wordpress themes and plugins, Best WooCommerce theme https://themeforest.net/user/janstudio/portfolio?ref=janstudio -
July 18, 2018 at 8:14 pm #22934
Hi Harry,
OK I understood, I was thinking about the file /wp-content/plugins/woocommerce/templates/archive-product.php
but you speak about /wp-content/themes/claue/core/libraries/vendors/woocommerce/templates/archive-product.php
So I have deleted code in child theme /wp-content/themes/claue-child/woocommerce/archive-product.php
and added in /var/www/cclub/wp-content/themes/claue-child/views/header/layout-3.php like below
<!– .jas-mini-cart –>
<?php endif ?><?php if ( is_active_sidebar( ‘wc-categories’ ) ) : ?>
<?php if ( ! function_exists( ‘dynamic_sidebar’ ) || ! dynamic_sidebar( ‘wc-categories’ ) ) : endif; ?><?php endif; ?>
</header><!– #jas-header –>
but still disappear on scroll and look wrong on product page, please see attached.
Attachments:
You must be logged in to view attached files. -
July 18, 2018 at 9:39 pm #22939
sorry your forum code is deleting div lines in my post
-
July 19, 2018 at 1:34 am #22946
Hi Mag,
Did you backup file layout-3.php in claue-child > Views > header?
I help you did it.
The new account it now can’t edit your site.
Please move code above line 95.
Best regards
Harry
Premium Wordpress themes and plugins, Best WooCommerce theme https://themeforest.net/user/janstudio/portfolio?ref=janstudio-
July 19, 2018 at 2:52 am #22954
Hi Harry,
yes OK, that works now I think, only it is a little bit delayed after scrolling first time, is it OK?
thank you very much.
-
-
July 19, 2018 at 10:21 am #22961
Hi,
This delay time because it change position after sticky. It Ok.
Harry
Premium Wordpress themes and plugins, Best WooCommerce theme https://themeforest.net/user/janstudio/portfolio?ref=janstudio
-
-
AuthorPosts
You must be logged in to reply to this topic.