ProCache CDN
Methods for managing ProCache CDN (Content Delivery Network) features.
Click any linked item for full usage details and examples. Hookable methods are indicated with the icon. In addition to those shown below, the Pro
class also inherits all the methods and properties of: Pro
Common
Name | Return | Summary | |
---|---|---|---|
$procache->cdn->allowCDN() $procache->cdn->allowCDN() $procache->cdn->allowCDN($page = null) | bool | Allow CDN to be used for this Page and request? | |
$procache->cdn->attrs() $procache->cdn->attrs() $procache->cdn->attrs(array $attrs = [], bool $replace = false) | array | Get or set runtime CDN HTML attributes | |
$procache->cdn->exts() $procache->cdn->exts() $procache->cdn->exts(array $exts = [], bool $replace = false) | array | Get or set runtime CDN file extensions | |
$procache->cdn->pathsToHosts() $procache->cdn->pathsToHosts() $procache->cdn->pathsToHosts($https = null) | array | Get array of CDN path to CDN host, i.e. [ '/site/' => 'cdn.domain.com/' ] | |
$procache->cdn->populateCDN() $procache->cdn->populateCDN($out) $procache->cdn->populateCDN($out, string $type = 'html') | bool | Populate CDN replacements | |
$procache->cdn->url() $procache->cdn->url(string $url) $procache->cdn->url(string $url, bool $requireExt = false) | string | Given a local URL convert to a CDN URL (if given URL is in CDN’s path space) |
Additional methods and properties
In addition to the methods and properties above, Pro
API reference based on ProcessWire core version 3.0.252