totalpoll/actions/init


Fired after initializing TotalPoll main components, defining some constants and registering hooks handlers.

— Purpose: initialize a plugin that depends on TotalPoll initialization.

Arguments passed: none

 
totalpoll/actions/request


Fired before processing a request (vote, results, etc…).

— Purpose: trigger webhook, change input, benchmark.

Arguments passed: TP_Request $request

 
totalpoll/actions/request/{$action}


Fired before processing a specific request (vote, results, etc…).

— Purpose: trigger webhook, change input, benchmark.

Arguments passed: TP_Request $request

 
totalpoll/actions/poll/vote


Fired after processing a successful vote request.

— Purpose: Save extra information, trigger webhook, send notification.

Arguments passed: TP_Poll $poll, array $log_entry

 
totalpoll/actions/poll/render/before


Fired before rendering a poll.

— Purpose: Change poll object.

Arguments passed: string $fragment, TP_Poll $poll

 
totalpoll/actions/poll/render/assets


Fired after enqueuing poll template assets.

— Purpose: Enqueuing other assets.

Arguments passed: string $fragment, TP_Poll $poll

 


Last updated on August 10, 2016