Changeset 3155374
- Timestamp:
- 09/20/2024 08:26:36 PM (7 weeks ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
jsm-show-comment-meta/trunk/lib/com/util-wp.php
r3152788 r3155374 1672 1672 * Returns false or the admin screen id string. 1673 1673 */ 1674 public static function get_screen_id( $screen = false) {1675 1676 if ( false === $screen) {1674 public static function get_screen_id( $screen = ) { 1675 1676 if ( ) { 1677 1677 1678 1678 if ( function_exists( 'get_current_screen' ) ) { … … 2356 2356 * raw_get_site_url() 2357 2357 * raw_set_url_scheme() 2358 2359 2360 2361 2358 2362 * raw_do_option() 2359 2363 * raw_delete_transient() … … 2679 2683 2680 2684 /* 2681 * Temporarily disable filters and actions hooks before calling get_option(), update_option(), and delete_option(). 2685 * Temporarily removes filter and action hooks before calling add_option(). 2686 */ 2687 public static function raw_add_option( $opt_name, $value = '', $deprecated = '', $autoload = null ) { 2688 2689 return self::raw_do_option( __FUNCTION__, $opt_name, $value, $default = false, $autoload ); 2690 } 2691 2692 /* 2693 * Temporarily removes filter and action hooks before calling delete_option(). 2694 */ 2695 public static function raw_delete_option( $opt_name ) { 2696 2697 return self::raw_do_option( __FUNCTION__, $opt_name, $value = null, $default = false, $autoload = null ); 2698 } 2699 2700 /* 2701 * Temporarily removes filter and action hooks before calling get_option(). 2702 */ 2703 public static function raw_get_option( $opt_name, $default = false ) { 2704 2705 return self::raw_do_option( __FUNCTION__, $opt_name, $value = null, $default, $autoload = null ); 2706 } 2707 2708 /* 2709 * Temporarily removes filter and action hooks before calling update_option(). 2710 */ 2711 public static function raw_update_option( $opt_name, $value, $autoload = null ) { 2712 2713 return self::raw_do_option( __FUNCTION__, $opt_name, $value, $default = false, $autoload ); 2714 } 2715 2716 /* 2717 * Temporarily removes filter and action hooks before calling add_option(), delete_option(), get_option(), and 2718 * update_option(). 2682 2719 */ 2683 2720 public static function raw_do_option( $action, $opt_name, $value = null, $default = false, $autoload = null ) { … … 2698 2735 case 'add': 2699 2736 case 'add_option': 2737 2700 2738 2701 2739 $success = add_option( $opt_name, $value, $deprecated = '', $autoload ); … … 2705 2743 case 'delete': 2706 2744 case 'delete_option': 2745 2707 2746 2708 2747 $success = delete_option( $opt_name ); … … 2712 2751 case 'get': 2713 2752 case 'get_option': 2753 2714 2754 2715 2755 $success = get_option( $opt_name, $default ); … … 2719 2759 case 'update': 2720 2760 case 'update_option': 2761 2721 2762 2722 2763 $old_value = get_option( $opt_name, $default ); … … 2736 2777 case 'update': 2737 2778 case 'update_option': 2779 2738 2780 2739 2781 switch( $opt_name ) {
Note: See TracChangeset
for help on using the changeset viewer.