Episode #125 of the Stack Overflow podcast is here. We talk Tilde Club and mechanical keyboards. Listen now
Jul
17
awarded  Popular Question
Mar
16
awarded  Famous Question
2018
Sep
6
awarded  Notable Question
2017
May
4
awarded  Notable Question
Mar
21
accepted How to show 1-5 of X Total Results
2016
Dec
16
awarded  Notable Question
Jun
25
awarded  Popular Question
Jun
4
awarded  Curious
Jun
3
awarded  Yearling
Jun
3
asked Location-Based Content
Jun
3
accepted Author Page Create Link to Page That Lists All Author's Posts?
Jun
2
asked Author Page Create Link to Page That Lists All Author's Posts?
Apr
28
accepted Getting the Most Recent Posts from Multiple Categories
Apr
27
asked Getting the Most Recent Posts from Multiple Categories
2015
Sep
16
comment Related Posts Excluding Certain Categories
Let us continue this discussion in chat.
Sep
16
comment Related Posts Excluding Certain Categories
Also, code is comments is definitely hard to read, but you said I needed to be more specific. Didn't know how to do both.
Sep
16
comment Related Posts Excluding Certain Categories
Sorry, I have my excluded category array in there, but do not know how to determine the taxonomy name or if it's built into the categories. How do I determine one or both of those?
Sep
16
comment Related Posts Excluding Certain Categories
Putting the following in the sidebar, I see nothing output: if ( function_exists( 'get_related_posts' ) ) { $related_posts = get_related_posts( 'my_taxonomy_name', // Taxonomy name, if build in, in should be 'category' [1, 2, 3] // Array of terms to exclude ); if ( $related_posts ) { foreach ( $related_posts as $post ) { setup_postdata( $post ); // Use your template tags and html mark up as normal like the_title(); the_content(); // etc etc } wp_reset_postdata(); } }
Sep
16
comment Related Posts Excluding Certain Categories
Function makes sense. Thanks, but I'm not getting any output using the default if statements you used above.
Sep
16
asked Related Posts Excluding Certain Categories