Language customize error Moodle 3.9.2+

Language customize error Moodle 3.9.2+

by Marini Marini -
Number of replies: 2

Hi

I have installed a moodle 3.9 and the option to customize a language does not appear in site administrator

If I put the address /admin/tool/customlang/index.php

the following error appears

Sorry, but you don't have the permissions to do this (Show local translation).

More information about this error

× Debug information:

Error code: nopermissions

× Stack trace:

line 870 of /lib/accesslib.php: required_capability_exception thrown

line 33 of /admin/tool/customlang/index.php: call to require_capability ()

any ideas

Thank you!!


Average of ratings: -
In reply to Marini Marini

Re: Language customize error Moodle 3.9.2+

by Michael Milette -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

Hi Marini,

The capability it is looking for is tool/customlang:view

The first thing I would try is to log into Moodle as an Administrator and use the Purge All Cache option in Moodle. You can do this by going to Site Administration > Development > Purge All  Caches. Then clear the cache and cookies in your web browser. Sometimes these  steps can help.

Next, ensure that your web hosting is properly configured and meets Moodle's system requirements. You can easily do this by going to Site Administration > Server > Environment. Ensure that there are no warnings or errors and address any that show up.

Make sure that your hosting platform has at least 1-2 CPUs, 1-2 GB of memory if running on a Linux server or 6-8 GB if running on Windows, and 20 GB of free disk space. Ensure that you have a swap file setup. I know a lot of providers hosting on SSD drives don't like this but it will save your site if it runs out of memory. Nobody likes running out of memory or disk space. Check with your hosting service provider to confirm all this. Note that you will need more than this depending on the number of concurrent active users you have and the number and size of your courses. However, if it is just you  and up to about 20 other people right now, you should be fine with the minimum.

Next, make sure cron is working and is set to run every 1 minute. You can check this by going to Site Administration > Notifications. If cron is not running regularly, a warning will be displayed on this page. If you don't see anything about cron on that page, it is likely configured and working just fine.

If your problem persists, something likely went wrong during or since your Moodle 3.9.3 installation. Did you modify any roles or install any 3rd party plugins? This section of the Moodle code has not changed in 5 years and I use it regularly, so I know it works.

If someone installed Moodle for you or you are using a different version of Moodle such as MoodleCloud, Moodle Workplace, Totara or IOMAD, the language editing functionality may be restricted by your hosting service provider.

Assuming you installed the regular Moodle 3.9.3 yourself, as a Moodle Administrator, you could try to fix the capabilities yourself by editing/resetting the system roles. If you cannot do this either, I suspect that this may not be the only problem on your site and continuing with it could result in other problems being uncovered down the road which may not be so easy to fix by then.

Unless you can determine what caused the problem, as a last resort, you might want to consider simply deleting your recently created site and starting over.

Hope you found something useful in all of this.

Best regards,

Michael Milette

In reply to Michael Milette

Re: Language customize error Moodle 3.9.2+

by Marini Marini -

thanks for your answer so detailed !!

I am testing all the options

I keep you informed if I get it

Thank you Michael !!