WC_Tracks_Client::queue_pixel_for_batch
Queue a pixel URL for batch sending.
Метод класса: WC_Tracks_Client{}
Хуков нет.
Возвращает
null. Ничего (null).
Использование
$result = WC_Tracks_Client::queue_pixel_for_batch( $pixel ): void;
- $pixel(строка) (обязательный)
- The pixel URL to queue.
Список изменений
| С версии 10.5.0 | Введена. |
Код WC_Tracks_Client::queue_pixel_for_batch() WC Tracks Client::queue pixel for batch WC 11.2.2
private static function queue_pixel_for_batch( string $pixel ): void {
self::$pixel_batch_queue[] = $pixel;
// Register shutdown hook once.
if ( ! self::$shutdown_hook_registered ) {
add_action( 'shutdown', array( __CLASS__, 'send_batched_pixels' ), 20 );
self::$shutdown_hook_registered = true;
}
}