Advertisement
fauzanjeg

Profecient || Disable Custom Cursor Feature

May 24th, 2024
615
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.73 KB | None | 0 0
  1. /**
  2.  * Disable Custom Cursor in Global Options
  3.  *
  4.  * @param array $options List Options.
  5.  *
  6.  * @return array
  7.  */
  8. function profeceient_disable_global_custom_cursor( $options ) {
  9.     if ( ( $key = array_search( 'Custom_Cursor', $options ) ) !== false ) {
  10.         unset( $options[ $key ] );
  11.     }
  12.     return $options;
  13. }
  14. add_filter( 'profecient_global_options', 'profeceient_disable_global_custom_cursor', 99 );
  15.  
  16. /**
  17.  * Disable Custom Cursor in each Widgets
  18.  *
  19.  * @param array $options Options.
  20.  *
  21.  * @return array
  22.  */
  23. function profeceient_disable_custom_cursor( $options ) {
  24.     unset( $options['profecient_custom_cursor'] );
  25.     return $options;
  26. }
  27. add_filter( 'profecient_register_custom_options', 'profeceient_disable_custom_cursor', 99 );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement