erichazann
Forum Replies Created
-
Forum: Plugins
In reply to: [Tweetily - Tweet Your Posts Automatically!] Excluding PagesI’m looking to do the same. In order to tweet my custom post types I had to set the tweet type to Pages and Posts and that tweets out everything, but I want to exclude all the pages.
I’m looking for help on the same subject. Any code hacks?
I only found one instance of the code you mention. The “second” instance of setting catlink is
$catlink = trailingslashit(get_option( 'home' )) . user_trailingslashit( $query_vars['category_redirect'], 'category' );
If you replace that with your code, you will break your redirects on old category URLs. You have to edit the code to swap out $category_nicename for $query_vars[‘category_redirect’]
Forum: Plugins
In reply to: wp_list_categories: highlight current category when viewing single postFirst, I assume most of you are using this code outside the loop in the global nav.
I just wanted to point something out… the title of this thread… “When viewing single post”.. if you alter your global nav with this code, you BREAK the built-in working functionality of the category archives where current-cat and current-parent-cat class flagging works just fine for highlighting.
Romeo_sat: your first conditional is not really needed, you don’t need to pass the current category param to wp_list_categories when you are on a category page.. if you do, you are passing it the param of THE FIRST POST.. that is what get_the_category does, it returns the categories for a single post.
This code should only be used with a is_single() conditional..