mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 08:56:36 +02:00
rss MDL-23391 alter the rss urls to be component names ie mod_forum instead of just module name ie forum
This commit is contained in:
parent
44c0751bbf
commit
aa60291e12
11 changed files with 48 additions and 62 deletions
|
@ -106,7 +106,7 @@ if ($cancel) {
|
|||
|
||||
/// RSS and CSS and JS meta
|
||||
if (!empty($CFG->enablerssfeeds) && !empty($CFG->data_enablerssfeeds) && $data->rssarticles > 0) {
|
||||
$rsspath = rss_get_url($context->id, $USER->id, 'data', $data->id);
|
||||
$rsspath = rss_get_url($context->id, $USER->id, 'mod_data', $data->id);
|
||||
$PAGE->add_alternate_version(format_string($course->shortname) . ': %fullname%',
|
||||
$rsspath, 'application/rss+xml');
|
||||
}
|
||||
|
|
|
@ -114,7 +114,7 @@ foreach ($datas as $data) {
|
|||
|
||||
$rsslink = '';
|
||||
if ($rss && $data->rssarticles > 0) {
|
||||
$rsslink = rss_get_link($context->id, $USER->id, 'data', $data->id, 'RSS');
|
||||
$rsslink = rss_get_link($context->id, $USER->id, 'mod_data', $data->id, 'RSS');
|
||||
}
|
||||
|
||||
if ($usesections) {
|
||||
|
|
|
@ -2874,7 +2874,7 @@ function data_extend_settings_navigation(settings_navigation $settings, navigati
|
|||
|
||||
$string = get_string('rsstype','forum');
|
||||
|
||||
$url = new moodle_url(rss_get_url($PAGE->cm->context->id, $USER->id, 'data', $data->id));
|
||||
$url = new moodle_url(rss_get_url($PAGE->cm->context->id, $USER->id, 'mod_data', $data->id));
|
||||
$datanode->add($string, $url, settings_navigation::TYPE_SETTING, null, null, new pix_icon('i/rss', ''));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -317,7 +317,7 @@
|
|||
//this links has been Settings (database activity administration) block
|
||||
/*if (!empty($CFG->enablerssfeeds) && !empty($CFG->data_enablerssfeeds) && $data->rssarticles > 0) {
|
||||
echo '<div style="float:right;">';
|
||||
rss_print_link($context->id, $USER->id, 'data', $data->id, get_string('rsstype'));
|
||||
rss_print_link($context->id, $USER->id, 'mod_data', $data->id, get_string('rsstype'));
|
||||
echo '</div>';
|
||||
echo '<div style="clear:both;"></div>';
|
||||
}*/
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue