Moodle APIs 3.9
Moodle 3.9.13+ (Build: 20220325)
Functions
rsslib.php File Reference

This file contains all the common stuff to be used in RSS System. More...

Functions

 rss_add_enclosures ($item)
 Adds RSS Media Enclosures for "podcasting" by including attachments that are specified in the item->attachments field. More...
 
 rss_add_http_header ($context, $componentname, $componentinstance, $title)
 Build the URL for the RSS feed and add it as a header. More...
 
 rss_add_items ($items)
 Generates the rss XML code for every item passed in the array. More...
 
 rss_delete_file ($componentname, $instance)
 Given an object, deletes all RSS files associated with it. More...
 
 rss_delete_token ($userid)
 Removes the token for the given user from the DB. More...
 
 rss_enabled_for_mod ($modname, $instance=null, $hasrsstype=true, $hasrssarticles=true)
 Are RSS feeds enabled for the supplied module instance? More...
 
 rss_end_tag ($tag, $level=0, $endline=true)
 Return the xml end tag. More...
 
 rss_full_tag ($tag, $level=0, $endline=true, $content, $attributes=null)
 Return the while xml element, including content. More...
 
 rss_get_file_full_name ($componentname, $filename)
 Retrieve the location and file name of a cached RSS feed. More...
 
 rss_get_file_name ($instance, $sql, $params=array())
 Construct the file name of the RSS File. More...
 
 rss_get_link ($contextid, $userid, $componentname, $id, $tooltiptext='')
 Print the link for the RSS feed with the correct RSS icon. More...
 
 rss_get_token ($userid)
 Get the RSS Token from a given user id. More...
 
 rss_get_url ($contextid, $userid, $componentname, $additionalargs)
 This function returns the URL for the RSS XML file. More...
 
 rss_get_userid_from_token ($token)
 Get the ID of the user from a given RSS Token. More...
 
 rss_geterrorxmlfile ($errortype='rsserror')
 This function return an error xml file (string) to be sent when a rss is required (file.php) and something goes wrong. More...
 
 rss_print_link ($contextid, $userid, $componentname, $id, $tooltiptext='')
 Print the link for the RSS feed with the correct RSS icon (Theme based) More...
 
 rss_save_file ($componentname, $filename, $contents, $expandfilename=true)
 This function saves to file the rss feed specified in the parameters. More...
 
 rss_standard_footer ()
 This function return all the common footers for every rss feed in the site. More...
 
 rss_standard_header ($title=NULL, $link=NULL, $description=NULL)
 This function return all the common headers for every rss feed in the site. More...
 
 rss_start_tag ($tag, $level=0, $endline=false, $attributes=null)
 Return the xml start tag. More...
 

Detailed Description

This file contains all the common stuff to be used in RSS System.