Last active
February 26, 2025 03:31
-
-
Save Crocoblock/1d1d0256efc8532a8861009e0b9b6d29 to your computer and use it in GitHub Desktop.
JetEngine Dynamic Tables Filter columns (process shortcodes in column names)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_filter( 'jet-engine/data-tables/table-columns', function( $columns ) { | |
| foreach ( $columns as $i => $column ) { | |
| if ( empty( $column['name'] ) ) { | |
| continue; | |
| } | |
| $columns[ $i ]['name'] = do_shortcode( $column['name'] ); | |
| } | |
| return $columns; | |
| } ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment