CMS integrations: Sticky CMS Navigation Block

CMS integrations: Sticky CMS Navigation Block

by Randy Orwin -
Number of replies: 2
We are looking to use Moodle for our entire web presence and have been fairly successfull in designing a theme that looks the way we want it.  I have been using the cms module to create menu structures for the home page, linking to the various departments at our district office.  Our consultant wants to see the same menu on all pages.

I setup a CMS navigation block on the sticky page configuration.  I can attach it to a menu but the menu items don't show up in any other courses other than the home page.  The block title does appear.  I am sure it is a permissions issue but don't have the coding skills to make it work correctly.  Janne, how difficult would it be to make the cms navigation blocks work as sticky blocks?
Average of ratings: -
In reply to Randy Orwin

Re: CMS integrations: Sticky CMS Navigation Block

by Janne Mikkonen -
Hi Randy,

The problem is not to get links to show up in navigation block, but get the pages to show up when blocks are somewhere else than frontpage or in course.
But if you're dealing with external links or resource or activity links only then It's shouldn't be that difficult task at all.
I'm pretty sure that you'll get the effect you need commenting out lines 133 - 135 from block_cmsnavigation.php file, meaning this:

        if ( $CFG->frontpage != FRONTPAGECMS && $SITE->id == $courseid ) {
         return $this->content;
     }


to this:

        //if ( $CFG->frontpage != FRONTPAGECMS && $SITE->id == $courseid ) {
     //    return $this->content;
     //}


- Janne -
In reply to Janne Mikkonen

Re: CMS integrations: Sticky CMS Navigation Block

by Randy Orwin -
Sticky blocks now work with the lates cms plugin.  Now all I need to do is figure out how to get a sticky block to show up on the site home page.