woocommerce_transient_file_contents_served

ACTION woocommerce\src\Internal\TransientFiles\TransientFilesEngine.php (ligne 537) github
Action that fires after a transient file has been successfully served, right before terminating the request.

Paramètres

Entrée :
$file_name
Sortie :
@param array $transient_file_info Information about the served file, as returned by get_file_by_name.
@param bool $is_json_rest_api_request True if the request came from the JSON API endpoint, false if it came from the authenticated endpoint.

Utilisation

// Ajouter une fonction au hook action 'woocommerce_transient_file_contents_served'
add_action('woocommerce_transient_file_contents_served', 'ma_fonction_personnalisee', 10, 1);

function ma_fonction_personnalisee($file_name) {
    // Votre code ici
    error_log('Hook woocommerce_transient_file_contents_served déclenché');
}

Actualités

Chargement des actualités...