sanitize_option callback in register_setting()
|Reported by:||digitalnature||Owned by:|
This is the user validation function you pass to register setting.
The problem is that if you're manually updating your option within this function, your option won't get updated because update_option() will run your callback on $newvalue, which changes it to the old option value. So it will do nothing because it would appear that both new and old values are identical.
I know there aren't many situations in which you would want to modify your option within that validation callback because that's what that callback should do in the first place, but they do exist :)