Zend Page Cache - PHP API

This topic lists the PHP API functions of the Zend Page Cache.

Zend Page Cache Functions

Function

Description

page_cache_disable_caching

Disables output caching for the current request. This overrides any caching settings that are configured for the current request.

page_cache_disable_compression

Does not allow the cache to perform compression on the output of the current request. This overrides any compression settings that are configured for this request.

page_cache_remove_cached_contents

Clears cached contents for all requests that match a specific URL or regular expression. The URL parameter should be the concatenation of the schema, host, and path of a caching rule.

page_cache_remove_cached_contents_by_rules_ids

Remove cached content by rule IDs

page_cache_remove_cached_contents_by_rule

Remove cached content by rule name

page_cache_remove_all_cached_contents

Clears all cached contents.

page_cache_remove_cached_contents_by_uri

Clears cached contents that were created by a specific URI in a specific rule. The rule must consist of one split condition/cache version - the request URI.

page_cache_disable_caching

Disables output caching for the current request. This overrides any caching settings that are configured for the current request.

Available Since Version: 4.0

page_cache_disable_compression

Does not allow the cache to perform compression on the output of the current request. This overrides any compression settings that are configured for this request.

Available Since Version: 4.0

page_cache_remove_cached_contents

Clears cached contents for all requests that match a specific URL or regular expression. The URL parameter should be the concatenation of the schema, host, and path of a caching rule.

Available Since Version: 4.0

Parameter

Type

Required

Description

URL

string

Yes

The URL or regular expression.

page_cache_remove_cached_contents_by_rules_ids

Remove cached content by rule IDs

Available Since Version: 6.0

Parameter

Type

Required

Description

ruleIds

array

Yes

Array of rule IDs

page_cache_remove_cached_contents_by_rule

Remove cached content by rule name

Available Since Version: 6.0

Parameter

Type

Required

Description

rulname

string

Yes

The rule name

page_cache_remove_all_cached_contents

Clears all cached contents.

Available Since Version: 4.0

Parameter

Type

Required

Description

clusterDelete

boolean

No

When set to true (the default), the API is applied across the cluster

page_cache_remove_cached_contents_by_uri

Clears cached contents that were created by a specific URI in a specific rule. The rule must consist of one split condition/cache version - the request URI.

Available Since Version: 6.0

Parameter

Type

Required

Description

ruleName

string

Yes

The rule name.

URI

string

Yes

The URI.

clusterDelete

boolean

No

When set to true (the default), the API is applied across the cluster

Return Value: boolean - True if successful. False otherwise

Code Sample:

<?php
        page_cache_remove_cached_contents_by_uri("My URI Rule", "/script.php");
?>