apply_filters( "{$filter_action}", array $filter_args, array $atts )
Filters the filter arguments depending on the action which is login and logout.
Description #
The dynamic part depends on the action attribute it will be learndash-login-shortcode-login for the login action and learndash-login-shortcode-logout for the logout action.
Parameters #
- $filter_args
-
(array) An Array of filter arguments with identifiers like label, icon, placement, class.
- $atts
-
(array) Shortcode Attributes.
Source #
Examples #
Note: Extended code example below not guaranteed, you may need to consult with a developer
<?php
/**
* Example usage for {$filter_action} filter.
*/
add_filter(
'learndash-login-shortcode-logout',
function( $filter_args, $atts ) {
// May add any custom logic using $filter_args, $atts.
// Always return $filter_args.
return $filter_args;
},
10,
2
);