WordPress.org

Make WordPress Core

Ticket #23692: 23692.2.diff

File 23692.2.diff, 1.7 KB (added by joostdevalk, 4 years ago)

Updated version of earlier general-template patch

  • wp-includes/general-template.php

     
    23062306
    23072307        $args = wp_parse_args( $args, $defaults );
    23082308
    2309         echo '<link rel="alternate" type="' . feed_content_type() . '" title="' . esc_attr( sprintf( $args['feedtitle'], get_bloginfo('name'), $args['separator'] ) ) . '" href="' . esc_url( get_feed_link() ) . "\" />\n";
    2310         echo '<link rel="alternate" type="' . feed_content_type() . '" title="' . esc_attr( sprintf( $args['comstitle'], get_bloginfo('name'), $args['separator'] ) ) . '" href="' . esc_url( get_feed_link( 'comments_' . get_default_feed() ) ) . "\" />\n";
     2309        /**
     2310         * Allows turning of the output of the posts feed
     2311         *
     2312         * @param bool unsigned  Whether to display the feed or not, defaults to true
     2313         */
     2314        if ( apply_filters( 'automatic_feed_links_show_posts_feed', true ) ) {
     2315                echo '<link rel="alternate" type="' . feed_content_type() . '" title="' . esc_attr( sprintf( $args['feedtitle'], get_bloginfo( 'name' ), $args['separator'] ) ) . '" href="' . esc_url( get_feed_link() ) . "\" />\n";
     2316        }
     2317
     2318        /**
     2319         * Allows turning of the output of the comments feed
     2320         *
     2321         * @param bool unsigned  Whether to display the feed or not, defaults to true
     2322         */
     2323        if ( apply_filters( 'automatic_feed_links_show_comments_feed', true ) ) {
     2324                echo '<link rel="alternate" type="' . feed_content_type() . '" title="' . esc_attr( sprintf( $args['comstitle'], get_bloginfo( 'name' ), $args['separator'] ) ) . '" href="' . esc_url( get_feed_link( 'comments_' . get_default_feed() ) ) . "\" />\n";
     2325        }
    23112326}
    23122327
    23132328/**