redirection_request_accept_language

redirection_request_accept_language

Hook Type: filter

See hook in core

Displaying hooks found in version: redirection.5.4.2

apply_filters('redirection_request_accept_language') is found 1 times:

  • /models/request.php line 252

    Warning: Undefined array key 257 in /home/c6974294/public_html/wp-plugin-api.com/wp-content/themes/wordpress-hooks/functions.php on line 167

    		if ( isset( $_SERVER['HTTP_ACCEPT_LANGUAGE'] ) && is_string( $_SERVER['HTTP_ACCEPT_LANGUAGE'] ) ) {
    			$languages = preg_replace( '/;.*$/', '', sanitize_text_field( $_SERVER['HTTP_ACCEPT_LANGUAGE'] ) );
    			$languages = str_replace( ' ', '', $languages );
    
    			return apply_filters( 'redirection_request_accept_language', explode( ',', $languages ) );
    		}
    
    		return [];
    	}
    }