totalpoll/filters/post-type/args


Called before passing post type arguments to WordPress.

— Purpose: Change a behavior in post type.

— Arguments passed: array $args

— Must return: array $args

 

totalpoll/filters/poll/vote/indexes


Called before processing submitted choices.

— Purpose: Change submitted choice to another one, manipulating choices votes.

— Arguments passed: array $indexes, TP_Poll $poll

— Must return: array $indexes

 

totalpoll/filters/poll/log


Called before saving a log entry.

— Purpose: Change a detail in log, add extra information, remove some information.

— Arguments passed: array $log, TP_Poll $poll

— Must return: array $log

 

totalpoll/filters/poll/render/content


Called before passing final rendered HTML to output.

— Purpose: Change, replace or remove some content from rendered HTML.

— Arguments passed: string $html, string $fragment, TP_Poll $poll

— Must return: string $html

 

totalpoll/filters/template/compile


Called after compiling template CSS when saving a poll in WordPress dashboard.

— Purpose: Add or change some CSS before cache it.

— Arguments passed: string $css, TP_Template $template

— Must return: string $css

 

totalpoll/filters/template/css


Called when CSS cached version isn’t readable or doesn’t exist.

— Purpose: Add or change some CSS or try to cache it in other way.

— Arguments passed: string $css, string $cache_path, TP_Template $template

— Must return: string $css

 

totalpoll/filters/template/stream/{$file}


Called after reading a file (template file) and before adding it to the stream.

— Purpose: Add, replace or remove some content when including a specific file.

— Arguments passed: string $content, string $stream_name, TP_Template $template

— Must return: string $content

 

totalpoll/filters/template/buttons


Called before rendering poll buttons.

— Purpose: Add, replace or remove a button.

— Arguments passed: array $buttons_objects, TP_Template $template

— Must return: array $buttons_objects

 

totalpoll/filters/template/hidden_fields


Called before rendering poll hidden fields.

— Purpose: Add, replace or remove a hidden field.

— Arguments passed: array $hidden_fields_objects, TP_Template $template

— Must return: array $hidden_fields_objects

 


Last updated on August 10, 2016