PHP Parse error: syntax error, unexpected 'terror_reporting'

268 views Asked by At

my site is not functioning at all this morning: The error log is pulling this message:

[02-Aug-2022 19:19:09 UTC] PHP Parse error: syntax error, unexpected 'terror_reporting' (T_STRING) in /home/arthomson/public_html/wp-load.php on line 71

This is the code on and around line 71, line 71 begins with "terror_reporting":

if ( function_exists( 'error_reporting' ) ) {

t/*

t * Initialize error reporting to a known set of levels.

t *

t * This will be adapted in wp_debug_mode() located in wp-includes/load.php based on WP_DEBUG.

t * @see http://php.net/manual/en/errorfunc.constants.php List of known error levels.

t */

terror_reporting( E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING | E_RECOVERABLE_ERROR );

}

At first I thought the issue was due to the phrase "terror" instead of "error" but that does not seem to make a difference.

1

There are 1 answers

0
scole01 On

Hi @braydenf17 I've seen this recently too. It looks like the server was hacked/accessed by someone who added "t" or "tt" to the start of many lines within the wp-load.php and wp-config.php files.

This brought down the WordPress website and could only be fixed again by editing those 2 files and removing all of the t/tt that had been added to multiple lines.

I also found a file called hi5.php, that only contained the word "hi", uploaded to multiple directories.

Googling for reference to a "hi5.php" hack returned no decent results. Must be a new thing...