Section

Blocks ::: block_section
Maintained by Arnaud Trouvé, Logo andilAndil Technologies de l'information et de la formation
The Section block displays the contents of a course section as a block.
Latest release:
32 sites
57 downloads
11 fans
Current versions available: 2

The Section block displays the contents of a course section as a block.

The section displayed and the block title are configurable per instance.
The block is hidden when the specified section does not exist.

The latest version can display sections from other courses.

Screenshots

Screenshot #0
Screenshot #1

Contributors

Arnaud Trouvé (Lead maintainer)
Logo andil
Andil Technologies de l'information et de la formation
Nathan Robbins: Original maintainer
Please login to view contributors details and/or to contact them

Comments RSS

Comments

  • Just wondering . . .
    Wed, 29 Aug 2012, 7:48 AM
    Any chance of a screen shot?
    -Derek
  • Just wondering . . .
    Sat, 3 Nov 2012, 11:23 AM
    Having another look at this. I'm not exactly sure of the purpose of this block. Does it show just the contents of the current section in single section view, or one particular section on every view??
    What is the meaning of "contents"? Does a label get displayed?
    I'm intrigued by the comment "The latest version can display sections from other courses" Could we have a section that has qualification information linked to in this block on every course in the qual?
    Is there somewhere in the universe where this block is, and I could see it in action?

    -Derek
  • Nathan Robbins
    Mon, 5 Nov 2012, 9:23 PM
    My main reason for creating the block was to display the activities and resources from a section of one course on the page of another course. The activities and resources, including labels, appear exactly as they would in the original section (though long text will wrap due to the narrow width of blocks). This can be used to display a common activity in a meta-course on the child courses, child-course sections in a meta-course page, or forums from a site-wide community discussion course.

    What do you mean by qualification information? I am not familiar with that term in this context.

    Unfortunately, I don't have a public example. Most of my work is done for employee education within my company.
  • My Hero
    Tue, 25 Feb 2014, 10:33 AM
    Hi,

    Any chance of having this block upgraded to work in moodle 2.6? When editing is turned on I get the error:

    Coding error detected, it must be fixed by a programmer: PHP catchable fatal error
    Debug info: Argument 1 passed to make_editing_buttons() must be an instance of stdClass, instance of cm_info given, called in [dirroot]/blocks/section/block_section.php on line 154 and defined
    Error code: codingerror
    Stack trace:

    line 393 of /lib/setuplib.php: coding_exception thrown
    line 2419 of /lib/deprecatedlib.php: call to default_error_handler()
    line 154 of /blocks/section/block_section.php: call to make_editing_buttons()
    line 775 of /blocks/moodleblock.class.php: call to block_section->get_content()
    line 238 of /blocks/moodleblock.class.php: call to block_list->formatted_contents()
    line 956 of /lib/blocklib.php: call to block_base->get_content_for_output()
    line 1008 of /lib/blocklib.php: call to block_manager->create_block_contents()
    line 353 of /lib/blocklib.php: call to block_manager->ensure_content_created()
    line 6 of /theme/canvas/layout/general.php: call to block_manager->region_has_content()
    line 870 of /lib/outputrenderers.php: call to include()
    line 800 of /lib/outputrenderers.php: call to core_renderer->render_page_layout()
    line 252 of /course/view.php: call to core_renderer->header()

    Thanks,
    Paul
  • My Hero
    Tue, 25 Feb 2014, 10:48 AM
    As a dirty hack, I commented out line 154 and the error is gone. I am positive there is a better way to do this, but I hope there aren't any adverse effects.
  • Arnaud Trouvé
    Mon, 2 Dec 2019, 10:08 PM
    Hi Nathan,

    I forked your repo and done some changes to make it compatible with recent moodle versions. (https://github.com/andil-elearning/moodle_block_section/tree/release/3.0.0)
    It seems you are not longer maintaining it, so I'd like to adopt it.
    If you are OK with this could you change the repository ownership and add me as maintainer in the Moodle plugin DB please ?

    TIA
    Arnaud Trouvé
  • Arnaud Trouvé
    Tue, 7 Jan 2020, 12:36 AM
    Thanks David Mudrák for setting me as maintainer and Thanks Nathan for the original work on this plugin !

    As explained in my previous message I have updated the plugin to work with recent moodle versions (tested on Moodle 3.5 and 3.8).
    It can be find at : https://github.com/andil-elearning/moodle_block_section/tree/release/3.0.0
    I'll try to do a proper release ASAP.
Please login to post comments