Add a new subscription to, or update an existing subscription in,
FWP's list of subscribed feeds.
Postcondition: If $rss is the URL of a feed not yet on FWP's list of
subscribed feeds, then a new subscription will be added, using $name
as its initial title and $uri as its initial homepage URL (normally
these will be updated with new values taken from the feed, the first
time the new feed is checked for syndicated content, unless feed
settings prevent this). If $rss is the URL of a feed that is already
on FWP's list of subscribed feeds, then that feed will be updated to
use the title provided in $name and the homepage URL in $uri
public static syndicate_link ( string $name, string $uri, string $rss ) : mixed | ||
$name | string | The human-readable title of the feed (for example, "Rad Geek People's Daily") |
$uri | string | The URI for the human-readable homepage associated with the feed (for example, |
$rss | string | The URI for the feed itself (for example, |
return | mixed | Returns an int with the numeric ID of the new subscription's wp_links record if successful or a WP_Error object if wp_insert_link() failed. |