Showing Wishlist Count
Showing total number of wishlist is very easy. Use addonify_wishlist_get_total_items()
helper function to display total number of items in current users wishlist. If you also use .addonify-wishlist-count
css class than the number will auto update when ever user adds or removes items from “addonify wishlist” plugin.
Example
<p class="addonify-wishlist-count"> <?php echo addonify_wishlist_get_total_items(); ?> </p>
Showing Wishlist count in sidebar toggle button
Use following code snippets to show total number of wishlists in sidebar toggle button without modifying the template.
add_filter( 'addonify_wishlist_sidebar_btn_label', 'show_wishlist_count', 10, 2 ); function show_wishlist_count( $btn_label, $total_items ) { $btn_label .= ' (<span class="addonify-wishlist-count">' . $total_items . '</span>)'; return $btn_label; }
Have fun.