He claims that this scheme worked in the old Moodle (2.7?). In the current version, 3.1, the users face "You can not enroll yourself in this course". Where is the catch?
That doesn't sound correct - without guest access enabled for the course, I don't see how they could access it without enrolling...
Thanks for looking at this. Yes, I am suspicious too that this scheme worked. There must have been something more. But left if open because i never understood the need of the Guest Login from the beginning.
Anyway, there are two ways of following this. First path is to find out why it doesn't work. If I assign somebody the Teacher role in a course category, that person automatically appears as teacher in every course in the category. Why not the Guest role?
The second path is to leave the philosophy behind us and find how this could be achieved. Ideally by editing the new "Registered User" role. The teacher enrolling these guests in their courses would be a workaround at most.
I'm not at my computer atm but from memory I recall a role needs to have https://docs.moodle.org/en/Capabilities/enrol/category:synchronised - has this been done?
Sounds promising. No, enrol/category:synchronised was not set. I changed it to Allow, but the "Registered" Guest still gets, "You can not enrol yourself in this course". The reference you gave, https://docs.moodle.org/en/Capabilities/enrol/category:synchronised, says "This capability is for use with the Category enrolments enrolment plugin." So obviously I need to install that plug-in?
Responding to your question "Why not the Guest role?" - this would be because the guest role is a whole separate animal and does get added manually in the way other roles do.
Can you edit the permissions of the guest role at the category level so that they can enter courses without enrolment?
Can you get access to the old Moodle where it worked and see the role permissions/definition? If the built-in Guest role was copied, it might have gotten additional permissions granted, and easiest way to replicate it is to find out what those permissions were.
The "forensics" are not important. I have site backups of all major upgrades. Not worth reconstructing. This role is something very old which I have inherited but newer touched. More important is to get the effect the users are asking for.
@Emma and Mary
It looks like the effect of category:synchronised was just delayed. I have asked the users to test the result. Will confirm here, once I hear from them.