Heads up!
This article contains PHP code and is intended for developers. We offer this code as a courtesy, but don't provide support for code customizations or 3rd party development.
This article contains PHP code and is intended for developers. We offer this code as a courtesy, but don't provide support for code customizations or 3rd party development.
Use this hook to allow filtering the table view CSS class.
Usage
add_filter( 'frm_views_table_class', 'table_view_class', 10, 2 );
Parameters
- $table_class (string): The table class.
- $args (array):
- $options (array): View options.
Examples
Add custom class for table view
add_filter( 'frm_views_table_class', 'table_view_class', 10, 2 );
function table_view_class( $table_class, $args ) {
// Remove zebra styling.
$table_class = str_replace( 'frm-alt-table', '', $table_class );
// Add custom class.
$table_class .= ' your-custom-class';
return $table_class;
}