Hiding navigation block on the frontpage

Hiding navigation block on the frontpage

by Paul K -
Number of replies: 4

Hi,

I'm wondering why it is not possible, at least in my Moodle instance (3.1) to hide the navigation block for the Guests?  I have already changed the permissions for the navigation block, capability: moodle/block:view and changed the defaultroleid on the frontpage to guest.

It doesn't have any effect at all. The navigation block still appears. Any suggestions?


Best regards

Paul

Average of ratings: -
In reply to Paul K

Re: Hiding navigation block on the frontpage

by Mary Cooch -
Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators

I tried this on our sandbox site demo.moodle.net. Please see Blocks FAQ

I didn't change the default front page role.

I turned on the editing and went to the navigation block and then Permissions and clicked the X to remove guests from being able to view the navigation block. When I logged out again, non-logged in users (ie anyone who just comes to the site) do not see the navigation block.

In reply to Mary Cooch

Re: Hiding navigation block on the frontpage

by Paul K -

Dear Mary,


thank you for your prompt reply. This is exactly what I have done. Nevertheless this problem appears in my instance, so I need to carefully check my system configuration.


Thank you and best regards,

Paul

In reply to Paul K

Re: Hiding navigation block on the frontpage

by Charles Krengel eLearn Solutions -

Hi Paul

Did you try removing guest view permissions of Navigation block within Front Page Settings ?

I tried removing guest view permission from the Navigation block on another page and it did not work.

Only when I removed guest view permission from the Navigation block within Front Page Settings did Navigation block stop displaying on the Landing page.


Charles

In reply to Paul K

Re: Hiding navigation block on the frontpage

by Martin Greenaway -

Hi Paul,

I realise this is old now, but it may help others as I've stumbled across it from a search - I think the reason yours was not responding to removing the guest permission from the navigation block was probably due to either one or more of these settings being something other than the default values:

  • Site administration --> Front page --> Front page settings --> Default frontpage role
  • Site administration --> Users --> Permissions --> User policies --> Role for visitors *and* Role for guests

I am not 100% certain which combinations would work in your specific scenario, but the removal of guest permissions on a block has the desired effect when these settings have default values.

Regards,

Martin