Moodle
  1. Moodle
  2. MDL-13248

RSS feeds for all courses in site and all courses in categories

    Details

    • Type: New Feature New Feature
    • Status: Open
    • Priority: Minor Minor
    • Resolution: Unresolved
    • Affects Version/s: 2.0, 2.5
    • Fix Version/s: None
    • Component/s: Course
    • Labels:
      None
    • Database:
      PostgreSQL
    • Affected Branches:
      MOODLE_20_STABLE, MOODLE_25_STABLE
    • Rank:
      4098

      Description

      I have created a new feature that makes RSS feeds for all the courses on the site, and also feeds for each categories.

      I believe Jenny Gray of The Open University had asked you if we could commit this feature to core.

      There is a new setting in the RSS admin area that controls the amount of items within all these feeds, and also in each category settings you have to enable the RSS feeds.

      I have also changed it so that if you make a course visible or hidden it changes the timemodified stamp in the database as it uses this field to see if the feed needs updating.

      There is a couple of issues that I do not know how to solve these are:-

      a) I currently use the timemodified field in the course table to work out if the course has change so that I can move it to the top of the RSS field. Unfortunately this only seems to change when you change the course settings. Should I use another method to work out if the course has changed? i.e. loop through all the course modules and get the time stamp those modules where updated. This would also suffer from a similar problem because the time stamp of those modules gets changed when the module settings are changed and that shouldn't really be classed as an update.

      b) Any sites with a whole bunch of courses could suffer a performance hit as I get all the courses from the database and place them into an array for later use. This could be tided up but I did not have time to re-factor that code. Would someone be able to look at this in the future, it should not cause any issues to normal sized sites.

      Martin ( either one You both know Moodle well! ) could you please cast you eye over the patch attached. This is the first time I have ever committed to core and I would like an experts opinion on the code before I commit. I have created the RSS stuff as an object rather than a lose collection of functions as I believe that is the way you wanted to go with Moodle I hope this was the correct way

      Currently the code has only been tested on the PostgreSQL database as that's all we have here at the OU.

      There will also be another new feature I will be working on which is the searching and filtering system we have on openlearn.open.ac.uk/course and labspace.open.ac.uk/course which will also display links to the feeds. I haven't put in any links in the normal core code as I wasn't sure where they should reside.

      If you are happy with me committing this patch, wish me to change any of the code, or just have questions please contact me on j [dot] e [dot] c [dot] brisland [at] open [dot] ac [dot] uk

      Thanks,

      James Brisland.

        Activity

        Hide
        James Brisland added a comment -

        Patch file for RSS cron thingy.

        Show
        James Brisland added a comment - Patch file for RSS cron thingy.
        Hide
        Martin Dougiamas added a comment -

        Thanks, I'll look at this soon. Please keep bugging me if I don't (just comment on this bug to send me mail)

        Show
        Martin Dougiamas added a comment - Thanks, I'll look at this soon. Please keep bugging me if I don't (just comment on this bug to send me mail)
        Hide
        Jenny Gray added a comment -

        Martin, you asked to be bugged, so here goes. Any chance you could review this some time fairly soon so we can get it committed? Sorry to nag!

        Show
        Jenny Gray added a comment - Martin, you asked to be bugged, so here goes. Any chance you could review this some time fairly soon so we can get it committed? Sorry to nag!
        Hide
        Nadav Kavalerchik added a comment -

        It could help improve the Moodle Hub server (Harvest courses services)
        which I plan to set up for our entire education system (Here in Israel) so...
        Martin Dougiamas, consider yourself bugged

        Show
        Nadav Kavalerchik added a comment - It could help improve the Moodle Hub server ( Harvest courses services ) which I plan to set up for our entire education system (Here in Israel) so... Martin Dougiamas , consider yourself bugged
        Hide
        Nadav Kavalerchik added a comment -

        Looking more into this...
        It might be wise to consider complying with a standardized harvesting protocol OAI-PMH
        https://github.com/agroknow/agrimoodle/tree/master/blocks/oai_target

        Show
        Nadav Kavalerchik added a comment - Looking more into this... It might be wise to consider complying with a standardized harvesting protocol OAI-PMH https://github.com/agroknow/agrimoodle/tree/master/blocks/oai_target
        Hide
        Jenny Gray added a comment -

        The patch in this issue is from Moodle 1.9, very out of date. I'd completely forgotten that we'd offered it! The OU has recently written two local plug-ins for RSS and OAI-PMH as part of migrating this functionality into Moodle 2. They are part of our open courseware collection and so weren't intended to work on their own, but I'm happy to share them with suitable caveats - they're beta code right now, not being used on any live OU system - if there's any interest?

        Show
        Jenny Gray added a comment - The patch in this issue is from Moodle 1.9, very out of date. I'd completely forgotten that we'd offered it! The OU has recently written two local plug-ins for RSS and OAI-PMH as part of migrating this functionality into Moodle 2. They are part of our open courseware collection and so weren't intended to work on their own, but I'm happy to share them with suitable caveats - they're beta code right now, not being used on any live OU system - if there's any interest?
        Hide
        Nadav Kavalerchik added a comment -

        Jenny, is this code suited for the HUB or more for a standard Moodle server?
        Does it expose Courses, Activities or Resources (or simple files) as entities?

        Show
        Nadav Kavalerchik added a comment - Jenny, is this code suited for the HUB or more for a standard Moodle server? Does it expose Courses, Activities or Resources (or simple files) as entities?
        Hide
        Jenny Gray added a comment -

        It exposes courses only and we wrote it for a standard (open) moodle server. I don't know what would happen if you put it on a hub.

        Show
        Jenny Gray added a comment - It exposes courses only and we wrote it for a standard (open) moodle server. I don't know what would happen if you put it on a hub.

          People

          • Votes:
            2 Vote for this issue
            Watchers:
            7 Start watching this issue

            Dates

            • Created:
              Updated: