Notice: These forums are now retired and closed. For active support, please Submit a Ticket or visit our official WordPress.org community pages.
Kadence Theme | Kadence Blocks | Starter Templates | WooCommerce Email Designer | Ascend | Virtue | Pinnacle
Search Results for 'sidebar'
-
AuthorSearch Results
-
In forum: Virtue Theme
Hello, I’d like to change the size of social media icons in the sidebar to something larger. I found a post that shows how to change it in the topbar using CSS as follows:
.topbarmenu ul li a {
font-size: 18px;What would the code be for the sidebar? I should specify, this is for the Virtue theme. Thanks!
In forum: Virtue ThemeIn reply to: Specific sidebar for each category
June 17, 2014 at 7:51 am #10917} elseif( class_exists('woocommerce') and (is_product_category() || is_product_tag())) { global $virtue_premium; $sidebar = $virtue_premium['shop_cat_sidebar']; if (is_product_category('funk') || is_product_category('bikers') || is_product_category('sports')) { dynamic_sidebar('test'); } else if (is_product_category('musique') || is_product_category('dance')){ dynamic_sidebar('test2'); } else if (!empty($sidebar)) { dynamic_sidebar($sidebar); } else { dynamic_sidebar('sidebar-primary'); }Just adding an else if right after works.
BenIn forum: Virtue ThemeIn reply to: Specific sidebar for each category
Ok great Ben,it works.
So as I have to add many categories I did like this for the “Test side bar”:// } elseif( class_exists('woocommerce') and (is_product_category() || is_product_tag())) { global $virtue_premium; $sidebar = $virtue_premium['shop_cat_sidebar']; if (is_product_category('funk') || is_product_category('bikers') || is_product_category('sports')){dynamic_sidebar('test'); } else if (!empty($sidebar)) { dynamic_sidebar($sidebar); } else { dynamic_sidebar('sidebar-primary'); } //Then I try to copy below this code to add the categories for the “Test2 sidebar” :
// } elseif( class_exists('woocommerce') and (is_product_category() || is_product_tag())) { global $virtue_premium; $sidebar = $virtue_premium['shop_cat_sidebar']; if (is_product_category('funk') || is_product_category('bikers') || is_product_category('sports')){dynamic_sidebar('test'); } else if (!empty($sidebar)) { dynamic_sidebar($sidebar); } else { dynamic_sidebar('sidebar-primary'); } // } elseif( class_exists('woocommerce') and (is_product_category() || is_product_tag())) { global $virtue_premium; $sidebar = $virtue_premium['shop_cat_sidebar']; if (is_product_category('musique') || is_product_category('dance')){dynamic_sidebar('test2'); } else if (!empty($sidebar)) { dynamic_sidebar($sidebar); } else { dynamic_sidebar('sidebar-primary'); } //But I do not think it is the right way to add the others sidebar possibilities, probably a wrong way of writing if, I am not a coder 🙁
It still works for the “TestSidebar1” but not for the “Testsidebar2”.
Thanks again a lot for helping Ben
DamienIn forum: Virtue ThemeIn reply to: Specific sidebar for each category
June 16, 2014 at 10:28 pm #10897ok but thats a product category page not a blog category page so it’s different.
<?php if(is_front_page()) { global $virtue_premium; $sidebar = $virtue_premium['home_sidebar']; if (!empty($sidebar)) { dynamic_sidebar($sidebar); } else { dynamic_sidebar('sidebar-primary'); } } elseif( class_exists('woocommerce') and (is_shop())) { global $virtue_premium; $sidebar = $virtue_premium['shop_sidebar']; if (!empty($sidebar)) { dynamic_sidebar($sidebar); } else { dynamic_sidebar('sidebar-primary'); } } elseif( class_exists('woocommerce') and (is_product_category() || is_product_tag())) { global $virtue_premium; $sidebar = $virtue_premium['shop_cat_sidebar']; if (is_product_category('musique')) { dynamic_sidebar('test'); } else if (!empty($sidebar)) { dynamic_sidebar($sidebar); } else { dynamic_sidebar('sidebar-primary'); } } elseif (class_exists('woocommerce') and is_product()) { global $post; $sidebar = get_post_meta( $post->ID, '_kad_sidebar_choice', true ); if (empty($sidebar) || $sidebar == 'default') { global $virtue_premium; $psidebar = $virtue_premium['product_sidebar_default_sidebar']; if(!empty($psidebar)) { dynamic_sidebar($psidebar); } else { dynamic_sidebar('sidebar-primary'); } } else if(!empty($sidebar)) { dynamic_sidebar($sidebar); } else { dynamic_sidebar('sidebar-primary'); } } elseif( is_page_template('page-blog.php') || is_page_template('page-blog-grid.php') || is_page_template('page-sidebar.php') || is_page_template('page-feature-sidebar.php') || is_single() ) { global $post; $sidebar = get_post_meta( $post->ID, '_kad_sidebar_choice', true ); if (!empty($sidebar)) { dynamic_sidebar($sidebar); } else { dynamic_sidebar('sidebar-primary'); } } elseif (is_archive()) { global $virtue_premium; if(isset($virtue_premium['blog_cat_sidebar'])) { dynamic_sidebar($virtue_premium['blog_cat_sidebar']); } else { dynamic_sidebar('sidebar-primary'); } } elseif(is_category()) { global $virtue_premium; if(isset($virtue_premium['blog_cat_sidebar'])) { dynamic_sidebar($virtue_premium['blog_cat_sidebar']); } else { dynamic_sidebar('sidebar-primary'); } } elseif (is_tag()) { dynamic_sidebar('sidebar-primary'); } elseif (is_post_type_archive()) { dynamic_sidebar('sidebar-primary'); } elseif (is_day()) { dynamic_sidebar('sidebar-primary'); } elseif (is_month()) { dynamic_sidebar('sidebar-primary'); } elseif (is_year()) { dynamic_sidebar('sidebar-primary'); } elseif (is_author()) { dynamic_sidebar('sidebar-primary'); } elseif (is_search()) { global $virtue_premium; if(isset($virtue_premium['search_sidebar'])) { dynamic_sidebar($virtue_premium['search_sidebar']); } else { dynamic_sidebar('sidebar-primary'); } } else { dynamic_sidebar('sidebar-primary'); } ?>Ben
In forum: Virtue ThemeIn reply to: Specific sidebar for each category
In forum: Virtue ThemeIn reply to: Specific sidebar for each category
Yes it is a category page : http://teeshirtdivision.com/categorie-produit/musique/
I try to show the sidebar “test” that I made in the back office.
I have added this code :<?php if(is_front_page()) { global $virtue_premium; $sidebar = $virtue_premium['home_sidebar']; if (!empty($sidebar)) { dynamic_sidebar($sidebar); } else { dynamic_sidebar('sidebar-primary'); } } elseif( class_exists('woocommerce') and (is_shop())) { global $virtue_premium; $sidebar = $virtue_premium['shop_sidebar']; if (!empty($sidebar)) { dynamic_sidebar($sidebar); } else { dynamic_sidebar('sidebar-primary'); } } elseif( class_exists('woocommerce') and (is_product_category() || is_product_tag())) { global $virtue_premium; $sidebar = $virtue_premium['shop_cat_sidebar']; if (!empty($sidebar)) { dynamic_sidebar($sidebar); } else { dynamic_sidebar('sidebar-primary'); } } elseif (class_exists('woocommerce') and is_product()) { global $post; $sidebar = get_post_meta( $post->ID, '_kad_sidebar_choice', true ); if (empty($sidebar) || $sidebar == 'default') { global $virtue_premium; $psidebar = $virtue_premium['product_sidebar_default_sidebar']; if(!empty($psidebar)) { dynamic_sidebar($psidebar); } else { dynamic_sidebar('sidebar-primary'); } } else if(!empty($sidebar)) { dynamic_sidebar($sidebar); } else { dynamic_sidebar('sidebar-primary'); } } elseif( is_page_template('page-blog.php') || is_page_template('page-blog-grid.php') || is_page_template('page-sidebar.php') || is_page_template('page-feature-sidebar.php') || is_single() ) { global $post; $sidebar = get_post_meta( $post->ID, '_kad_sidebar_choice', true ); if (!empty($sidebar)) { dynamic_sidebar($sidebar); } else { dynamic_sidebar('sidebar-primary'); } //} elseif (is_archive()) { // global $virtue_premium; //if(isset($virtue_premium['blog_cat_sidebar'])) { //dynamic_sidebar($virtue_premium['blog_cat_sidebar']); //} else { //dynamic_sidebar('sidebar-primary'); //} //} } elseif (is_archive()) { global $virtue_premium; if (is_category(‘musique’)) { dynamic_sidebar(‘test’); } else if(isset($virtue_premium['blog_cat_sidebar'])) { dynamic_sidebar($virtue_premium['blog_cat_sidebar']); } else { dynamic_sidebar('sidebar-primary'); } } elseif(is_category()) { global $virtue_premium; if(isset($virtue_premium['blog_cat_sidebar'])) { dynamic_sidebar($virtue_premium['blog_cat_sidebar']); } else { dynamic_sidebar('sidebar-primary'); } } elseif (is_tag()) { dynamic_sidebar('sidebar-primary'); } elseif (is_post_type_archive()) { dynamic_sidebar('sidebar-primary'); } elseif (is_day()) { dynamic_sidebar('sidebar-primary'); } elseif (is_month()) { dynamic_sidebar('sidebar-primary'); } elseif (is_year()) { dynamic_sidebar('sidebar-primary'); } elseif (is_author()) { dynamic_sidebar('sidebar-primary'); } elseif (is_search()) { global $virtue_premium; if(isset($virtue_premium['search_sidebar'])) { dynamic_sidebar($virtue_premium['search_sidebar']); } else { dynamic_sidebar('sidebar-primary'); } } else { dynamic_sidebar('sidebar-primary'); } ?>In forum: Virtue ThemeIn reply to: Specific sidebar for each category
June 16, 2014 at 10:43 am #10805Using the slug should work, this is a post category right? I’m just looking at the code and instead of get sidebar is should be dynamic_sidebar.. like this:
} elseif (is_archive()) { global $virtue_premium; if (is_category(‘music’)) { dynamic_sidebar(‘sidebarmusic’); } else if(isset($virtue_premium['blog_cat_sidebar'])) { dynamic_sidebar($virtue_premium['blog_cat_sidebar']); } else { dynamic_sidebar('sidebar-primary'); } }In forum: Virtue ThemeIn reply to: Specific sidebar for each category
In forum: Virtue ThemeIn reply to: Specific sidebar for each category
June 16, 2014 at 1:33 am #10785Hey so you will want to edit the templates/sidebar.php not the one in the lib folder.
on line 49- 56 you will see:
} elseif (is_archive()) { global $virtue_premium; if(isset($virtue_premium['blog_cat_sidebar'])) { dynamic_sidebar($virtue_premium['blog_cat_sidebar']); } else { dynamic_sidebar('sidebar-primary'); } }you can change to:
} elseif (is_archive()) { global $virtue_premium; if (is_category(‘music’)) { get_sidebar(‘sidebarmusic’); } else if(isset($virtue_premium['blog_cat_sidebar'])) { dynamic_sidebar($virtue_premium['blog_cat_sidebar']); } else { dynamic_sidebar('sidebar-primary'); } }Ben
In forum: Virtue ThemeHello I am trying to add a specific sidebar for each category page.
I found this code<?php if (is_category(‘music’)) {
get_sidebar(‘sidebarmusic’);
} else {
get_sidebar();
} ?>I tried to add it in the sidebar.php but it doesn’t seems to work. Could you tell me where it should be added ?
I think many users are interested in changing their sidebar in the category pages.Thanks a lot
In forum: Virtue ThemeIn reply to: gallery suggestions
I got my avatar working. I just installed a plugin. The blog response page is coming along. I do have two problems I can’t seem to solve though. Here is the page link, http://www.baywatcharms.com/?p=434#virtue_comments , the about author section has no background, and i can’t seem to find where I can css over ride in advance settings. Also, The response page seems to be set up with a sidebar. Is there a way I can change to no sidebar on the response page?
In forum: Virtue ThemeIn reply to: page content title
June 12, 2014 at 6:20 pm #10583That page has a sidebar which is why the post is on the left. Your sidebar just doesn’t have any widgets in it. If you want to have the page without the sidebar you can do that in the page settings: http://docs.kadencethemes.com/virtue/#blogpage
Ben
In forum: Virtue ThemeIn reply to: home page picture layout
June 12, 2014 at 12:36 pm #10502You are using the page template: feature-sidebar.
Which has a built in slider: http://docs.kadencethemes.com/virtue/#featuresidebarpage
BenIn forum: Virtue ThemeTopic: woocommerce sidebar
In forum: Virtue ThemeIn reply to: Woocommerce sidebars
June 9, 2014 at 10:01 am #10315Hey,
Yes using the woosidebars is a good trick and easier then the needed additional functions.Ben
In forum: Virtue ThemeIn reply to: Woocommerce sidebars
In forum: Virtue ThemeIn reply to: Child Theme How to?
Hi Ben,
Many thanks, So updates should not effect the site. Thats good to know, but I will do a backup when its finished!
I know the basics of HTML and how to change the things I want in CSS, I was just looking for a quick way to style the sidebar to match the sites main CSS. I have Contact Form 7 on a page, and at the moment, RSS feed, and Links (blogroll feed) in a sidebar. May add twit feed etc later.
I looked at some of the links text in the blogroll, using firefox, as far as I could tell, it was reading H4 from the CSS, but it does not render as such.
Anyway, I will do some research and plow on.
Thanks,
Graeme.
In forum: Virtue ThemeIn reply to: Woocommerce sidebars
OK, sidebars back! (Once I had removed the PHP tags around the function 😉 ). Client happy!
Only slight problem now is that, although I have told Virtue to use an alternative sidebar on all shop pages, it now reverts to the ordinary sidebar on account, cart and checkout pages.
I think I can use a WooCommerce plugin (edit: ‘WooSidebars’) to rectify this for the moment though. (Unless you’ve got another super-wizzy function for this as well!)
Cheers,
Colin
In forum: Virtue ThemeIn reply to: Woocommerce sidebars
June 8, 2014 at 11:45 pm #10276Hey so theme design is not to have a sidebar on those pages. It was a design decision. But you can add theme with a custom function. I recommend using a child theme. You can download an empty one here:
https://www.kadencewp.com/wp-content/uploads/2014/02/virtue_premium_child.zipThen just add this to your functions.php file.
<?php add_filter('kadence_display_sidebar', 'kad_sidebar_on_woopages'); function kad_sidebar_on_woopages($sidebar) { if (is_cart() || is_checkout() || is_account_page()) { return true; } return $sidebar; } ?>Ben
In forum: Virtue ThemeTopic: Woocommerce sidebars
-
AuthorSearch Results


