Tribe__Cache::set_last_occurrence( string $action, int|float $timestamp )
Sets the time (microtime) for an action last occurrence.
Contents
Parameters
- $action
-
(string) (Required) The action to record the last occurrence of.
- $timestamp
-
(int|float) (Required) The timestamp to assign to the action last occurrence or the current time (microtime).
Return
(boolean) IF we were able to set the last occurrence or not.
Source
File: src/Tribe/Cache.php
public function set_last_occurrence( $action, $timestamp = 0 ) {
if ( empty( $timestamp ) ) {
$timestamp = time();
}
update_option( 'tribe_last_' . $action, (int) $timestamp );
}
Changelog
| Version | Description |
|---|---|
| 4.9.14 | Introduced. |