Support

Akeeba Backup for WordPress

#39513 User interface shows code instead of control element texts

Posted in ‘Akeeba Backup for WordPress’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Environment Information

WordPress version
6.3.1
PHP version
8.0.28
Akeeba Backup version
7.9.2

Latest post by nicholas on Sunday, 24 September 2023 14:48 CDT

julian

Hello all,

I'm desperate - for years I've been using Akeeba Backup (Core) for WordPress without any problems - and now this.

The user interface shows code instead of control element texts (see attached screenshots).

I am not even able to download your log file.

Can you please help?

Thank you very much!!!

Best regards,

Julian

nicholas
Akeeba Staff
Manager

Try deleting the folder wp-content/plugins/akeebabackupwp/app/tmp/compiled_templates. It will be created afresh and populated as you visit pages in the plugin.

If this does not help, is it possible that you restored a backup of your site taken with a version of the software prior to 7.9.0?

Nicholas K. Dionysopoulos

Lead Developer and Director

🇬🇷Greek: native 🇬🇧English: excellent 🇫🇷French: basic • 🕐 My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

julian

Hi Nicholas, I deleted the folder wp-content/plugins/akeebabackupwp/app/tmp/compiled_templates. But it shows still the same behaviour. Even if I deactivate Akeeba Backup, delete it and install it freshly the issue remains.

nicholas
Akeeba Staff
Manager

The interface is distributed as Blade templates (files with a .blade.php extension) which have a mix of plain old PHP and a template metalanguage called Blade. These files need to be compiled to plain old PHP before they are used to display the interface.

The compilation of Blade files can use either the PHP Tokenizer extension (very fast, but not always available) or standard PHP string replacement (slower, but always available; if it wasn't available WordPress itself wouldn't work).

The decision on which method to use is based on asking PHP to tell us if both the token_get_all() PHP function and the T_INLINE_HTML constant exist. If they both exist, we use PHP Tokenizer. If either or both don't exist we fall back to the slower string replacement.

Since you get the completely uncompiled Blade code it means that both the token_get_all() PHP function and the T_INLINE_HTML constant exist, but they do not actually work. Since ether exist, we use the PHP Tokenizer, i.e. a call to the token_get_all() function, to try and compile the Blade template instead of falling back to string replacement. However, since calling token_get_all() returns bogus information nothing is actually replaced in the Blade file, therefore it's not compiled, it is simply copied over verbatim.

Frankly, I have never seen the PHP Tokenizer being broken like that before. However, I've seen my fair share of weird bollocks on production sites and commercial hosts.

First, ask your host if the PHP Tokenizer extension is enabled on your site. If it's not, ask them to enable it. It is possible that a third party plugin is doing something stupid, e.g. detecting that token_get_all() is not defined and use their own, broken implementation. That is in line with other stupid things I have seen plugin authors do.

If they tell you that the PHP Tokenizer extension is enabled on your site, please let your host know it's broken.

Just to be on the safe side, I am going to implement a workaround for sites broken in the same way yours is, but this will happen in the next release (scheduled for this week, assuming we finish our tests successfully tomorrow).

Nicholas K. Dionysopoulos

Lead Developer and Director

🇬🇷Greek: native 🇬🇧English: excellent 🇫🇷French: basic • 🕐 My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

Support Information

Working hours: We are open Monday to Friday, 9am to 7pm Cyprus timezone (EET / EEST). Support is provided by the same developers writing the software, all of which live in Europe. You can still file tickets outside of our working hours, but we cannot respond to them until we're back at the office.

Support policy: We would like to kindly inform you that when using our support you have already agreed to the Support Policy which is part of our Terms of Service. Thank you for your understanding and for helping us help you!