# Hooks

- [Actions](#actions)
- [Filters](#filters)

## Actions

### `after_purge_url`

*Runs immediately after a URL is purged.*

Varnish HTTP Purge Compatibility

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`$url` | `string` | The original URL that was purged.
`$purge_url` | `string` | The URL that was purged.
`$response` | `array` | The response from the purge request.
`$headers` | `array` | The headers sent with the purge request.

**Changelog**

Version | Description
------- | -----------
`1.0.0` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 560](includes/classes/VarnishPurger.php#L560-L570)

### `xneelo_helper/action/after_purge_url`

*Runs immediately after a URL is purged.*

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`$url` | `string` | The original URL that was purged.
`$purge_url` | `string` | The URL that was purged.
`$response` | `array` | The response from the purge request.
`$headers` | `array` | The headers sent with the purge request.

**Changelog**

Version | Description
------- | -----------
`1.0.0` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 571](includes/classes/VarnishPurger.php#L571-L580)

### `after_full_purge`

*Runs immediately after a full purge.*

Varnish HTTP Purge Compatibility


**Changelog**

Version | Description
------- | -----------
`1.0.0` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 602](includes/classes/VarnishPurger.php#L602-L608)

### `after_full_purge`

*Runs immediately after a full purge.*


**Changelog**

Version | Description
------- | -----------
`1.0.0` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 609](includes/classes/VarnishPurger.php#L609-L614)

### `xneelo_helper/action/missing_plugins`

*Runs just after the plugin dependencies have been checked.*

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`__NAMESPACE__` |  | 
`$missing_plugins` | `array` | The list of missing plugins.

**Changelog**

Version | Description
------- | -----------
`0.0.1` | 

Source: [./includes/classes/PluginDependencies.php](includes/classes/PluginDependencies.php), [line 59](includes/classes/PluginDependencies.php#L59-L66)

## Filters

### `xneelo_helper/filter/locate_template_paths`

*Allows you to manipulate the paths that are searched when loading a template within this plugins namespace.*

:NOTE: The order if important, the paths are searched in order and the first template found is returned.

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`$paths_to_search` | `array` | Contains an array of strings

Source: [./includes/classes/Plugin.php](includes/classes/Plugin.php), [line 164](includes/classes/Plugin.php#L164-L170)

### `vhp_home_url`

*Filter the home URL - Varnish HTTP Purge Compatibility*

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`home_url()` |  | 

**Changelog**

Version | Description
------- | -----------
`1.0.0` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 182](includes/classes/VarnishPurger.php#L182-L188)

### `xneelo_helper/filter/home_url`

*Filter the home URL*

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`$home_url` | `string` | 

**Changelog**

Version | Description
------- | -----------
`` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 189](includes/classes/VarnishPurger.php#L189-L195)

### `xneelo_helper/filter/purge_post_events`

*HTTP Purge Post Events
These are the actions that trigger the purge event*

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`/**
 * HTTP Purge Post Events  - Varnish HTTP Purge Compatibility
 * These are the actions that trigger the purge event
 *
 * @since 1.0.0
 * @param array $actions the actions that trigger the purge event
 */
apply_filters($actions)` |  | 

**Changelog**

Version | Description
------- | -----------
`1.0.0` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 321](includes/classes/VarnishPurger.php#L321-L338)

### `varnish_http_purge_events`

*HTTP Purge Post Events  - Varnish HTTP Purge Compatibility
These are the actions that trigger the purge event*

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`$actions` | `array` | the actions that trigger the purge event

**Changelog**

Version | Description
------- | -----------
`1.0.0` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 330](includes/classes/VarnishPurger.php#L330-L337)

### `xneelo_helper/filter/purge_all_events`

*HTTP Purge All Events
These are the actions that trigger the purge event*

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`/**
 * HTTP Purge All Events  - Varnish HTTP Purge Compatibility
 * These are the actions that trigger the purge event
 *
 * @since 1.0.0
 * @param array $actions the actions that trigger the purge event
 */
apply_filters($actions)` |  | 

**Changelog**

Version | Description
------- | -----------
`1.0.0` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 359](includes/classes/VarnishPurger.php#L359-L376)

### `varnish_http_purge_events_full`

*HTTP Purge All Events  - Varnish HTTP Purge Compatibility
These are the actions that trigger the purge event*

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`$actions` | `array` | the actions that trigger the purge event

**Changelog**

Version | Description
------- | -----------
`1.0.0` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 368](includes/classes/VarnishPurger.php#L368-L375)

### `xneelo_helper/filter/purge_schema`

*HTTP Purge Schema*

Allows default https:// schema to be changed to http://

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`/**
 * HTTP Purge Schema - Varnish HTTP Purge Compatibility
 * Allows default https:// schema to be changed to http://
 *
 * @since 1.0.0
 * @param array $actions the actions that trigger the purge event
 */
apply_filters('https://')` |  | 

**Changelog**

Version | Description
------- | -----------
`1.0.0` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 472](includes/classes/VarnishPurger.php#L472-L489)

### `varnish_http_purge_schema`

*HTTP Purge Schema - Varnish HTTP Purge Compatibility
Allows default https:// schema to be changed to http://*

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`'https://'` |  | 

**Changelog**

Version | Description
------- | -----------
`1.0.0` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 481](includes/classes/VarnishPurger.php#L481-L488)

### `vhp_purgeme_path`

*Filter the purge path - Varnish HTTP Purge Compatibility*

Allows dynamically changing the purge cache for custom purge location
or systems not supporting .* regex purge for example

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`$purge_url` |  | 
`$schema` |  | 
`$one_host` |  | 
`$path` |  | 
`$pregex` |  | 
`$parsed_url` |  | 

**Changelog**

Version | Description
------- | -----------
`1.0.0` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 508](includes/classes/VarnishPurger.php#L508-L516)

### `xneelo_helper/filter/purge_url`

*Filter the purge path - Varnish HTTP Purge Compatibility*

Allows dynamically changing the purge cache for custom purge location
or systems not supporting .* regex purge for example

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`$purge_url` |  | 
`$schema` |  | 
`$one_host` |  | 
`$path` |  | 
`$pregex` |  | 
`$parsed_url` |  | 

**Changelog**

Version | Description
------- | -----------
`1.0.0` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 517](includes/classes/VarnishPurger.php#L517-L525)

### `varnish_http_purge_headers`

*Filters the HTTP headers to send with a PURGE request. - Varnish HTTP Purge Compatibility*

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`['host' => $host_headers, 'X-Purge-Method' => $x_purge_method]` |  | 

**Changelog**

Version | Description
------- | -----------
`1.0.0` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 527](includes/classes/VarnishPurger.php#L527-L538)

### `xneelo_helper/filter/purge_headers`

*Filters the HTTP headers to send with a PURGE request.*

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`$headers` |  | 

**Changelog**

Version | Description
------- | -----------
`1.0.0` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 539](includes/classes/VarnishPurger.php#L539-L547)

### `vhp_purge_urls`

*Filter to add or remove urls to the array of purged url - Varnish HTTP Purge Compatibility*

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`$this->purge_urls` |  | 
`$post_id` | `int` | the id of the new/edited post

**Changelog**

Version | Description
------- | -----------
`1.0.0` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 865](includes/classes/VarnishPurger.php#L865-L872)

### `xneelo_helper/filter/purge_urls`

*Filter to add or remove urls to the array of purged url*

**Arguments**

Argument | Type | Description
-------- | ---- | -----------
`$this->purge_urls` |  | 
`$post_id` | `int` | the id of the new/edited post

**Changelog**

Version | Description
------- | -----------
`1.0.0` | 

Source: [./includes/classes/VarnishPurger.php](includes/classes/VarnishPurger.php), [line 873](includes/classes/VarnishPurger.php#L873-L880)


<p align="center"><a href="https://github.com/pronamic/wp-documentor"><img src="https://cdn.jsdelivr.net/gh/pronamic/wp-documentor@main/logos/pronamic-wp-documentor.svgo-min.svg" alt="Pronamic WordPress Documentor" width="32" height="32"></a><br><em>Generated by <a href="https://github.com/pronamic/wp-documentor">Pronamic WordPress Documentor</a> <code>1.2.0</code></em><p>

