Changeset 45772
- Timestamp:
- 08/09/2019 01:30:32 AM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/feed.php
r45753 r45772 617 617 618 618 /** 619 * Returns the link for the currently displayed feed. 620 * 621 * @since 5.3.0 622 * 623 * @return string Correct link for the atom:self element. 624 */ 625 function get_self_link() { 626 $host = @parse_url( home_url() ); 627 return set_url_scheme( 'http://' . $host['host'] . wp_unslash( $_SERVER['REQUEST_URI'] ) ); 628 } 629 630 /** 619 631 * Display the link for the currently displayed feed in a XSS safe way. 620 632 * … … 624 636 */ 625 637 function self_link() { 626 $host = @parse_url( home_url() );627 638 /** 628 639 * Filters the current feed URL. … … 635 646 * @param string $feed_link The link for the feed with set URL scheme. 636 647 */ 637 echo esc_url( apply_filters( 'self_link', set_url_scheme( 'http://' . $host['host'] . wp_unslash( $_SERVER['REQUEST_URI'] )) ) );648 echo esc_url( apply_filters( 'self_link', get_self_link() ) ); 638 649 } 639 650
Note: See TracChangeset
for help on using the changeset viewer.