Support Forum

Please login to receive premium support.

Support for the free plugin can be found here.

Connor

Forum Replies Created

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • in reply to: Show Related Posts & Exclude Post #19222
    Connor
    Participant

    Awesome, thanks, Tom!

    in reply to: Show Related Posts & Exclude Post #18882
    Connor
    Participant

    Awesome, thanks Tom! I’m glad I’m not going crazy! Should it be possible to exclude both the current post and my own selected exclusions once this is fixed?

    in reply to: Show Related Posts & Exclude Post #18845
    Connor
    Participant

    Yes, 3401 is the current post. I do have a number of other custom functions added through Snippets, but none of them are related to WP Show Posts.

    in reply to: Show Related Posts & Exclude Post #18827
    Connor
    Participant

    Hi Tom,

    Here’s what is showing with “Exclude current” unchecked and post 3595 listed to be excluded:

    array(8) { ["order"]=> string(4) "desc" ["orderby"]=> string(4) "date" ["post_type"]=> string(4) "post" ["posts_per_page"]=> int(3) ["ignore_sticky_posts"]=> bool(true) ["post_status"]=> array(1) { [0]=> string(7) "publish" } ["tax_query"]=> array(1) { [0]=> array(4) { ["taxonomy"]=> string(8) "category" ["field"]=> string(4) "slug" ["terms"]=> array(1) { [0]=> string(6) "saving" } ["operator"]=> string(2) "IN" } } ["post__not_in"]=> array(1) { [0]=> int(3401) } }

    in reply to: Show Related Posts & Exclude Post #18786
    Connor
    Participant

    Oddly, even when I uncheck that option, it is still excluding the current post and not the one I have specified.

    in reply to: Show Related Posts & Exclude Post #18782
    Connor
    Participant

    Hey Tom,

    I have confirmed this is the list that is hooked in below the post content, so I don’t think that’s the issue. 3401 is the current post which it is excluding (per the checkbox in the “More” settings). However, it doesn’t seem to be excluding post-ID 3595 as well.

    in reply to: Show Related Posts & Exclude Post #18775
    Connor
    Participant

    It’s showing the following

    array(8) { ["order"]=> string(4) "desc" ["orderby"]=> string(4) "date" ["post_type"]=> string(4) "post" ["posts_per_page"]=> int(3) ["ignore_sticky_posts"]=> bool(true) ["post_status"]=> array(1) { [0]=> string(7) "publish" } ["tax_query"]=> array(1) { [0]=> array(4) { ["taxonomy"]=> string(8) "category" ["field"]=> string(4) "slug" ["terms"]=> array(1) { [0]=> string(6) "saving" } ["operator"]=> string(2) "IN" } } ["post__not_in"]=> array(1) { [0]=> int(3401) } }

    in reply to: Show Related Posts & Exclude Post #18756
    Connor
    Participant

    Hi Tom,

    1. This shortcode works perfectly, thank you!

    2.Yes, Under WP Show Posts -> Selected List -> More Settings I have entered “3595” in the Exclude Post IDs field. For an example if where this shouldn’t be displaying, if you go to this post (https://afterschoolfinance.com/live-below-your-means/), the first post at the bottom where WP Show Posts displays is Christmas on a Budget. This is post 3595, which I have tried to exclude because it is seasonal.

    Thanks!

    in reply to: Show Post Category Next to Date #16767
    Connor
    Participant

    Hi there!

    I was able to get the category next to the date with the built-in option. To remove the link from the date I added:

    add_filter( 'wpsp_date_output', 'tu_wpsp_updated_date_first' );
    function tu_wpsp_updated_date_first() {
    	$time_string = '';
    	
    	$time_string .= '<time class="wp-show-posts-entry-date published" datetime="%1$s" itemprop="datePublished">%2$s</time>';
    	
    	$time_string = sprintf( $time_string,
    		esc_attr( get_the_date( 'c' ) ),
    		esc_html( get_the_date() ),
    		esc_attr( get_the_modified_date( 'c' ) ),
    		esc_html( get_the_modified_date() )
    	);
    	
    	// If our date is enabled, show it
    	$output = sprintf(
    		'<span class="wp-show-posts-posted-on wp-show-posts-meta">
    			%1$s
    		</span>',
    		$time_string
    	);
    
    	return $output;
    	
    }

    This does work (though I am not sure if the PHP is done right, as I was copying code from the forum and then modifying to take out the modified date part.

    Thanks!

Viewing 9 posts - 1 through 9 (of 9 total)