Home » Documents » WeCodeArt Framework » Filters » Header » Clean Header Actions

Clean Header Actions


1

Views:
30

Hooking into wecodeart/filter/head/clean/actions can be done via add_filter WordPress function.

Bellow is an example of how to add extra functions to be “removed” from head.

function wecodeart_remove_head_extra( $actions ) {
$actions[] = [ 'wp_head', 'action_name', 20 ];

return $actions;
}
 
add_filter('wecodeart/filter/head/clean/actions','wecodeart_remove_head_extra')

Where $actions is the returned array and each item must have at least 2 arguments: 1 -> hook name, 2 -> action name (while the rest is priority and accepted arguments, the same as https://developer.wordpress.org/reference/functions/add_action/)

Was this article helpful to you?

Ready to create with WeCodeArt Framework?

WeCodeArt Framework is a base WP theme, Super Fast, Optimized and ready for any shape.