• Resolved bilpavel

    (@bilpavel)


    Hello!
    Custom rss feed not working after update to 4.7.
    I found new code in function do_feed() wp-includes/functions.php

    
    // Determine if we are looking at the main comment feed
    	$is_main_comments_feed = ( $wp_query->is_comment_feed() && ! $wp_query->is_singular() );
    
    	/*
    	 * Check the queried object for the existence of posts if it is not a feed for an archive,
    	 * search result, or main comments. By checking for the absense of posts we can prevent rendering the feed
    	 * templates at invalid endpoints. e.g.) /wp-content/plugins/feed/
    	 */
    	if ( ! $wp_query->have_posts() && ! ( $wp_query->is_archive() || $wp_query->is_search() || $is_main_comments_feed ) ) {
    		wp_die( __( 'ERROR: This is not a valid feed.' ), '', array( 'response' => 404 ) );
    	}
    

    After removing this code my rss feed working again.
    I can’t find information about rss changes in release note.

Viewing 6 replies - 1 through 6 (of 6 total)
  • Moderator t-p

    (@t-p)

    I found new code in function do_feed() wp-includes/functions.php
    After removing this code my rss feed working again.

    As the adage goes, don’t modify core files (unless you know what you are doing in there and are aware of the limitations and drawbacks this imposes). Modifications can cause:
    security risks,
    performance degradation,
    broken plugins/themes,
    you will lose all changes when you next update the WordPress, etc.

    Custom rss feed not working after update to 4.7.

    my recommendation is to talk to the designer of this “Custom” feed/theme.

    Thread Starter bilpavel

    (@bilpavel)

    I understand risks but i had no choice.
    I want to understand what i do wrong before new release

    Hi,
    I have the same problem after update. That’s my topic

    and nobody tells me how to solve it.

    Moderator t-p

    (@t-p)

    Thread Starter bilpavel

    (@bilpavel)

    up

    Thread Starter bilpavel

    (@bilpavel)

    This code are removed in version 4.7.3)

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘WP 4.7 custom rss feed problem’ is closed to new replies.