Theme selector 4.3

Theme selector 4.3

by Tony Enderby -
Number of replies: 6
Hi All,

Just performed an update from the latest 4.2 to 4.3 and after what appeared to be a successful upgrade, I've noticed this debug code? in the theme selector section of admin settings.  I am also unable to successfully select a different theme to classic.    Other areas of the site (at least the ones I've browsed through) appear to be functioning correctly.

Could anyone share any ideas about what might be causing this?

Server is debian 10 / apache and php 8.2

Thank-you - Tony.


Average of ratings: -
In reply to Tony Enderby

Re: Theme selector 4.3

by Mary Cooch (personal account) -
Picture of Documentation writers Picture of Testers
Hello - I am not a developer or technical but this is probably related to the removal of device specific themes here MDL-77793
In reply to Mary Cooch (personal account)

Re: Theme selector 4.3

by Tony Enderby -
Thank-you Mary, much appreciated.

It looks like the developers are still refactoring that area of theme management.

I'll see if I can find out anything else but would be interested to know if anyone else on v4.3 is experiencing the same issue.
In reply to Tony Enderby

Re: Theme selector 4.3

by Leon Stringer -
Picture of Core developers Picture of Particularly helpful Moodlers

line 154 of /theme/index.php: call to get_string(); line 160 of /theme/index.php: call to theme_is_device_locked()

It looks like you've got a mix of Moodle versions in your source code folder. For Moodle 4.3 theme/index.php only has 128 lines so presumably you've got the wrong version of this file from somewhere. It's probably best to update your site to the latest weekly release since if you have one wrong file you may have others.

Average of ratings: Useful (1)
In reply to Leon Stringer

Ri: Re: Theme selector 4.3

by Sergio Rabellino -
Picture of Particularly helpful Moodlers Picture of Plugin developers
I can confirm that in a correctly updated v4.3 this problem does not arise.
Average of ratings: Useful (1)
In reply to Sergio Rabellino

Re: Ri: Re: Theme selector 4.3

by Dr. Nellie Deutsch -
Picture of Particularly helpful Moodlers
Tony, I upgraded a few Moodle sites and the problem does not exist. I can select any of the themes available. However as Mary pointed out, device specific themes are no longer an option.
In reply to Tony Enderby

Re: Theme selector 4.3

by Tony Enderby -
Thanks a million for your help everyone.

Leon, you were correct. We were using a bash script written a few years ago which moved a backed up theme directory into the update directory which was causing the problem.

I made some changes to the script and all the issues on the theme page went away.

Tony.