PHP Class CacheBuster

Inheritance: extends CApplicationComponent
Mostra file Open project: openeyes/openeyes Class Usage Examples

Public Properties

Property Type Description
$time string The time string to append to the URL.

Public Methods

Method Description
createUrl ( string $url = '', string $time = null ) : string Create a cache busted URL.

Protected Methods

Method Description
getJoiner ( string $url = '' ) : string Determine the joiner required to append the cache busting string. This checks if the URL contains query string params and returns the appropriate joiner.

Method Details

createUrl() public method

Create a cache busted URL.
public createUrl ( string $url = '', string $time = null ) : string
$url string The URL to cache bust.
$time string The time string to append to the url.
return string The cache busted URL.

getJoiner() protected method

Determine the joiner required to append the cache busting string. This checks if the URL contains query string params and returns the appropriate joiner.
protected getJoiner ( string $url = '' ) : string
$url string The URL to check.
return string The joiner char (either '?' or '&')

Property Details

$time public_oe property

The time string to append to the URL.
public string $time
return string