The function apache_request_headers, doesn't exist in FCGI PHP-FPMUse this patch : https://gist.github.com/rmpel/11583cfddfcc9705578428e3a2ee3dc1<?phpif ( ! function_exists( 'apache_request_headers' ) ) { function apache_request_headers() { static $arrHttpHeaders; if ( ! $arrHttpHeaders ) { $arrCasedHeaders = array( 'Dasl' => 'DASL', 'Dav' => 'DAV', 'Etag' => 'ETag', 'Mime-Version' => 'MIME-Version', 'Slug' => 'SLUG', 'Te' => 'TE', 'Www-Authenticate' => 'WWW-Authenticate', 'Content-Md5' => 'Content-MD5', 'Content-Id' => 'Content-ID', 'Content-Features' => 'Content-features', ); $arrHttpHeaders = array(); foreach ( $_SERVER as $strKey => $mixValue ) { if ( 'HTTP_' !== substr( $strKey, 0, 5 ) ) { continue; } $strHeaderKey = strtolower( substr( $strKey, 5 ) ); if ( 0 < substr_count( $strHeaderKey, '_' ) ) { $arrHeaderKey = explode( '_', $strHeaderKey ); $arrHeaderKey = array_map( 'ucfirst', $arrHeaderKey ); $strHeaderKey = implode( '-', $arrHeaderKey ); } else { $strHeaderKey = ucfirst( $strHeaderKey ); } if ( array_key_exists( $strHeaderKey, $arrCasedHeaders ) ) { $strHeaderKey = $arrCasedHeaders[ $strHeaderKey ]; } $arrHttpHeaders[ $strHeaderKey ] = $mixValue; } if ( ! empty( $arrHttpHeaders['Authorization'] ) ) { if ( ! isset( $_SERVER['PHP_AUTH_USER'] ) ) { list( $_SERVER['PHP_AUTH_USER'], $_SERVER['PHP_AUTH_PW'] ) = explode( ':', base64_decode( substr( $_SERVER['HTTP_AUTHORIZATION'], 6 ) ) ); } } } return $arrHttpHeaders; } apache_request_headers();}