wpsc_accept_headers

wpsc_accept_headers

Hook Type: filter

See hook in core

Displaying hooks found in version: wp-super-cache.2.0.1

apply_filters('wpsc_accept_headers') is found 1 times:

  • /wp-cache-phase2.php line 537
    533
    534
    535
    536
    537
    538
    539
    540
    541
    542
    543
    function wpsc_get_accept_header() {
        static $accept = 'N/A';
     
        if ( $accept === 'N/A' ) {
            $accept_headers = apply_filters( 'wpsc_accept_headers', array( 'application/json', 'application/activity+json', 'application/ld+json' ) );
            $accept_headers = array_map( 'strtolower', $accept_headers );
            // phpcs:ignore WordPress.NamingConventions.ValidVariableName.VariableNotSnakeCase
            // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.MissingUnslash -- $accept is checked and set below.
            $accept = isset( $_SERVER['HTTP_ACCEPT'] ) ? strtolower( filter_var( $_SERVER['HTTP_ACCEPT'] ) ) : '';
     
            foreach ( $accept_headers as $header ) {