SimplePie::set_cache_duration()publicWP 1.0

Set the length of time (in seconds) that the contents of a feed will be cached

Method of the class: SimplePie{}

No Hooks.

Return

null. Nothing (null).

Usage

$SimplePie = new SimplePie();
$SimplePie->set_cache_duration( $seconds );
$seconds(int)
The feed content cache duration
Default: 3600

SimplePie::set_cache_duration() code WP 6.5.2

public function set_cache_duration($seconds = 3600)
{
	$this->cache_duration = (int) $seconds;
}