• Hi there,

    For some reason I’m now getting a 500 Internal Server error when I visit:

    https://www.mydomain.com/

    https://www.mydomain.com/wp-admin

    or: https://www.mydomain.com/wp-login

    When I look at the server I get to see this error:

    AH01215: PHP Fatal error: Array and string offset access syntax with curly braces is no longer supported in /mnt/web202/a1/60/59739660/htdocs/WordPress_01/wp-includes/script-loader.php on line 706: /home/strato/http/premium/rid/96/60/59739660/htdocs/WordPress_01/index.php

    I tried to chage the PHP to the next (the recommondated one) considering this one had an update. But it still isn’t working.

    Can someone help me also seeing the error message what to do to get my site back online and for me to get back into the backend / content place of the website.

    Kind regards,

    Jamie

    The page I need help with: [log in to see the link]

Viewing 5 replies - 1 through 5 (of 5 total)
  • Hey @jamievdpoel

    The array and string offset access syntax using curly braces?{}?is deprecated in PHP 7.4 and removed entirely in PHP 8.0.

    To fix this issue, you need to replace the curly braces?{}?with square brackets?[]?in the respective line of code.

    For example, if your code looks like this:?$array{0};, you would change it to:?$array[0];

    Thread Starter jamievdpoel

    (@jamievdpoel)

    Hi,

    Thank you for your quick response. Where in which file should I change this?

    What I did at the moment is that in the server it says setup-up PHP-version which I changed to the bulletpoint option 8.1 (recommended).

    Do I need to change those [ ] also somewhere in a file in the webspace? After changed it to the 8.1 I still don’t see the site online.

    Kind regards,

    Jamie

    @jamievdpoel

    Here: wp-includes/script-loader.php on line 706

    if that doesn’t work, here are some other ways: https://www.wpbeginner.com/wp-tutorials/how-to-fix-the-internal-server-error-in-wordpress/

    Thread Starter jamievdpoel

    (@jamievdpoel)

    Hi,

    Line 705: } elseif ( ! empty( $value ) && is_string( $value ) && (
    Line 706: ( ‘{‘ == $value{0} && ‘}’ == $value{strlen( $value ) – 1} ) ||
    Line 707: ( ‘[‘ == $value{0} && ‘]’ == $value{strlen( $value ) – 1} ) ||

    I tried to change the ( ‘{‘ == $value{0} && ‘}’ to ( ‘[‘ == $value{0} && ‘]’

    And I also tried: ( ‘{‘ == $value[0] && ‘}’

    Both don’t seem to do much.

    As for the blog I indeed tried to rename the htaccess file and plugins already.

    Should it been seen imidiatelly if the website works after one of these changes? Cause somehow after trying all this it unfortunatelly isn’t working yet but the hosting provider says it’s nothing at their site or they can do about.

    @jamievdpoel

    >>I tried to change the ( ‘{‘ == $value{0} && ‘}’ to ( ‘[‘ == $value{0} && ‘]’<<

    I suggested it based on the error you were getting. seems like that ain’t the issue here.

    >>As for the blog I indeed tried to rename the htaccess file and plugins already<<

    Go to your webhost panel and restart your web server. That does it for most cases. If not, rename plugins folder and see if you can get access to your website. If not check for URLs in wp-config.php file to make sure they are correct.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘HTTP ERROR 500’ is closed to new replies.