Automattic\WooCommerce\StoreApi
Authentication::allowed_cors_headers()
Add allowed cors headers for store API headers.
Метод класса: Authentication{}
Хуков нет.
Возвращает
Массив
.
Использование
$Authentication = new Authentication(); $Authentication->allowed_cors_headers( $allowed_headers );
- $allowed_headers(массив) (обязательный)
- Allowed headers.
Код Authentication::allowed_cors_headers() Authentication::allowed cors headers WC 9.8.4
public function allowed_cors_headers( $allowed_headers ) { $allowed_headers[] = 'Cart-Token'; $allowed_headers[] = 'Nonce'; return $allowed_headers; }