• HI,

    I don’t believe this problem has been reported previously, apologies if it has.

    I just upgraded to WordPress 6.3.1, which went fine, and then I updated “Create Block Theme” to 1.13.2.

    The plugin upgrade was green and reported no errors. However on refreshing the page the site was broken with “critical error on this website”

    Looking at the logs, the error was:

    [16-Sep-2023 21:14:05 UTC] PHP Parse error: syntax error, unexpected ‘string’ (T_STRING), expecting function (T_FUNCTION) or const (T_CONST) in /srv/www/zoyinc/wp-content/plugins/create-block-theme/admin/create-theme/cbt-zip-archive.php on line 8

    I edited cbt-zip-archive.php and changed line 8 from:

    private string $theme_slug;

    to

    private $theme_slug;

    My site is now back and working.

    From the reading I have done it seems the fact that I am stuck on 7.3 is part of the problem. I do plan to fix this but not at the moment.

    I am not a developer, so not proposing a solution but just letting you know.

    For the moment I simply won’t update the plugin.

    Cheers

Viewing 1 replies (of 1 total)
  • Hi @tpcantab ! I see that the plugin lists PHP 7.4 as the minimum requirement, and it’s expected that it will not work well on lower versions.

    PHP 7.3 has been deprecated since Dec 2021. If you’re stuck on 7.3 on your host, the best option is to ask them to update. As a stopgap measure, you can set up a local installation of WordPress to run this plugin, and export your theme to use on your main website.

Viewing 1 replies (of 1 total)
  • The topic ‘Unexpected ‘string’ (T_STRING) – upgrade on PHP7.3’ is closed to new replies.