Functions to handle the feeds (includes feed2array) More...
Functions | |
curl_downloader ($urls) | |
refresh_feeds ($feeds, $update_feeds_infos=false) | |
add_feeds ($urls) | |
delete_feed_id ($id) | |
delete_feed_url ($url) | |
edit_feed ($old_url, $new_url, $new_title='') | |
get_feeds () | |
Functions to handle the feeds (includes feed2array)
add_feeds | ( | $urls | ) |
Add feeds in the database and refresh them.
$urls | is an array of urls |
curl_downloader | ( | $urls | ) |
Downloads all the urls in the array $urls and returns an array with the results and the http status_codes.
Mostly inspired by blogotext by timovn : https://github.com/timovn/blogotext/blob/master/inc/fich.php
TODO : If open_basedir or safe_mode, Curl will not follow redirections : https://stackoverflow.com/questions/24687145/curlopt-followlocation-and-curl-multi-and-safe-mode
an | array $urls of URLs |
delete_feed_id | ( | $id | ) |
Remove a feed and all associated tags / entries based on its id
$id | is the id of the feed to delete |
delete_feed_url | ( | $url | ) |
Remove a feed and all associated tags / entries based on its url
$url | is the url of the feed to delete |
edit_feed | ( | $old_url, | |
$new_url, | |||
$new_title = '' |
|||
) |
Edit a feed in the database and refresh it.
TODO : Edit more than just the URL
$old_url | is the current URL of the feed |
$new_url | is the new URL to assign to this feed |
$new_title | (optionnal) is the new title of the feed |
get_feeds | ( | ) |
Returns all the available feeds.
TODO
refresh_feeds | ( | $feeds, | |
$update_feeds_infos = false |
|||
) |
Refresh the specified feeds and returns an array with URLs in error
TODO:
$feeds | should be an array of ids as keys and urls as values |
$update_feeds_infos | should be true to update the feed infos from values in the RSS / ATOM |