[wp-trac] [WordPress Trac] #11474: Add validation error reporting system to Settings API
WordPress Trac
wp-trac at lists.automattic.com
Thu Feb 18 16:33:21 UTC 2010
#11474: Add validation error reporting system to Settings API
----------------------------+-----------------------------------------------
Reporter: jeremyclarke | Owner: jeremyclarke
Type: enhancement | Status: new
Priority: high | Milestone: 3.0
Component: Administration | Version: 2.9
Severity: normal | Keywords: has-patch needs-testing
----------------------------+-----------------------------------------------
Comment(by jeremyclarke):
The new patch fixes the problem with the undefined index. Sorry about
that, rboren was right that I had stupidly changed the function's argument
without checking my uses of it. I've replaced the $id/$title argument with
one called $code, which is how the slug-names of errors are referred to in
WP_Error class, so this system is that much closer to integrating with
WP_Error.
rboren: I also changed the way the function_exists() call is done in
sanitize_option() because your setup was actually returning "1" as the
admin email when it was valid (because it was setting $value to the result
of the &&). I moved the actual sanitize_email() onto its own line and
everything seems to be working.
ptahdunbar really sorry that it was actually breaking things for you. If
I'd known I would have hussled with the patch.
rboren let me know if there's anything else wrong with it.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/11474#comment:16>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list