Update problem with update_option() in combination with register_setting()
Note what happens when you provide sanitize callback in register_setting(). It register a filter to sanitize your options add_filter( “sanitize_option_{$option_name}”, $sanitize_callback ); Now when you do update_option() then trigger your own function to prevent saving 😀 Because update_option() calls $value = sanitize_option( $option, $value ); Solution: Remove register_settings() callback before you call update_option(). function gtp_remove_installing_data() … Read more