Requests_Cookie_Jar::register() WordPress Method
The register() method of the Requests_Cookie_Jar class is used to register a new cookie jar with the WordPress HTTP API. This is useful for storing and retrieving cookies from the WordPress HTTP API.
Requests_Cookie_Jar::register( Requests_Hooker $hooks ) #
Register the cookie handler with the request’s hooking system
Contents
Parameters
- $hooks
(Requests_Hooker)(Required)Hooking system
Source
File: wp-includes/Requests/Cookie/Jar.php
public function register(Requests_Hooker $hooks) { $hooks->register('requests.before_request', array($this, 'before_request')); $hooks->register('requests.before_redirect_check', array($this, 'before_redirect_check')); }
Expand full source codeCollapse full source codeView on TracView on GitHub