block_rss_client/rsslib MDL-1393 Clean up

- Remove obsolete magpie configuration
- Remove block_rss_client_submitters which has not been used for some
  time
- Remove some block_rss_client setup from rsslib.php
This commit is contained in:
poltawski
2009-07-29 14:10:15 +00:00
parent 0864a0837b
commit 53fe72ee1f
4 changed files with 9 additions and 40 deletions
-30
View File
@@ -23,10 +23,6 @@
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
if (!defined('MAGPIE_OUTPUT_ENCODING')) {
define('MAGPIE_OUTPUT_ENCODING', 'utf-8'); // see bug 3107
}
/**
* This function returns the icon (from theme) with the link to rss/file.php
*
@@ -382,32 +378,6 @@ function rss_full_tag($tag,$level=0,$endline=true,$content,$attributes=null) {
return $st.$co.$et;
}
//////////////////// LIBRARY FUNCTIONS FOR RSS_CLIENT BLOCK ////////////////
//initialize default config vars for rss_client block if needed
if (!isset($CFG->block_rss_client_submitters) ) {
$CFG->block_rss_client_submitters = 1; //default to admin only
}
if (empty($CFG->block_rss_client_num_entries) ) {
$CFG->block_rss_client_num_entries = 5; //default to 5 entries per block
}
if (!isset($CFG->block_rss_client_timeout) ) {
$CFG->block_rss_client_timeout = 30; //default to 30 mins
}
// Defines for moodle's use of magpierss classes
define('MAGPIE_DIR', $CFG->libdir.'/magpie/');
define('MAGPIE_CACHE_DIR', $CFG->dataroot .'/cache/rsscache');
define('MAGPIE_CACHE_ON', true); //might want to expose as an admin config option, but perhaps this is something that should truly just be on unless the code is tweaked
define('MAGPIE_CACHE_FRESH_ONLY', false); //should be exposed as an admin config option
define('MAGPIE_CACHE_AGE', $CFG->block_rss_client_timeout * 60);
define('MAGPIE_DEBUG', $CFG->debug); // magpie, like moodle, takes an integer debug
// defines for config var block_rss_client_submitters
define('SUBMITTERS_ALL_ACCOUNT_HOLDERS', 0);
define('SUBMITTERS_ADMIN_ONLY', 1);
define('SUBMITTERS_ADMIN_AND_TEACHER', 2);
/**
* Adds RSS Media Enclosures for "podcasting" by examining links to media files,
* and attachments which are media files. Please note that the RSS that is