Support » Plugin: Cerber Security, Antispam & Malware Scan » Syntax Error in common.php

  • Resolved astrologeeks

    (@astrologeeks)


    Hi there, wordpress is failing to install the plugin because of a syntax error on line 1970 of common.php

    The fatal error is as follows:
    Parse error: syntax error, unexpected ‘[‘ in /home/rizecon/public_html/wp-content/plugins/wp-cerber/common.php on line 1970

    // @since v. 7.7 for PHP-FPM
    if ( ! function_exists( ‘getallheaders’ ) ) {
    function getallheaders() {
    $headers = [];
    foreach ( $_SERVER as $name => $value ) {
    if ( substr( $name, 0, 5 ) == ‘HTTP_’ ) {
    $headers[ str_replace( ‘ ‘, ‘-‘, ucwords( strtolower( str_replace( ‘_’, ‘ ‘, substr( $name, 5 ) ) ) ) ) ] = $value;
    }
    }

    return $headers;
    }
    }

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Syntax Error in common.php’ is closed to new replies.