record_event() static public méthode

record_event
static public record_event ( mixed $event ) : mixed
$event mixed Event object to send to Tracks. An array will be cast to object. Required. Properties are included directly in the pixel query string after light validation.
Résultat mixed True on success, WP_Error on failure
Exemple #1
0
/**
 * Procedurally (vs. Object-oriented), track an event object (or flat array)
 * NOTE: Use this only when the simpler jetpack_tracks_record_event() function won't work for you.
 * @param \Jetpack_Tracks_Event $event The event object.
 * @return \Jetpack_Tracks_Event|\WP_Error
 */
function jetpack_tracks_record_event_raw($event)
{
    return Jetpack_Tracks_Client::record_event($event);
}
 function record()
 {
     return Jetpack_Tracks_Client::record_event($this);
 }