Advertisement
eventsmanager

Untitled

Feb 18th, 2025
107
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.60 KB | None | 0 0
  1. /**
  2.  * This function sets the current default scope of the bookings table admin area if not saved by user.
  3.  *
  4.  * For information on how to paste/implement this snippet, see here - http://wp-events-plugin.com/tutorials/how-to-safely-add-php-code-to-wordpress/
  5.  *
  6.  * @param array $defaults
  7.  *
  8.  * @return array
  9.  */
  10. function my_em_bookings_table_get_default_settings( $defaults ) {
  11.     if ( empty( $defaults['filters']['scope'] ) ) {
  12.         $defaults['filters']['scope'] = 'future';
  13.     }
  14.     return $defaults;
  15. }
  16. add_filter( 'em_bookings_table_get_default_settings', 'my_em_bookings_table_get_default_settings' );
Tags: bookings
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement