[wp-trac] [WordPress Trac] #15729: Better UX after supplying incorrect information to setup-config
WordPress Trac
wp-trac at lists.automattic.com
Sat Dec 11 03:46:06 UTC 2010
#15729: Better UX after supplying incorrect information to setup-config
-----------------------------+----------------------------------------------
Reporter: nacin | Owner: kapeels
Type: defect (bug) | Status: accepted
Priority: low | Milestone: Future Release
Component: Upgrade/Install | Version:
Severity: normal | Keywords: gci has-patch
-----------------------------+----------------------------------------------
Changes (by nacin):
* keywords: gci has-patch 2nd-opinion => gci has-patch
Comment:
Minor thing, but watch for trailing whitespace.
Take a look at our coding standards:
http://codex.wordpress.org/WordPress_Coding_Standards. Function names
should be written with underscores separating the words.
I think we can avoid a new function all together. That would also avoid
the overuse of globals here. What we can do is create our own WP_Error
object, then modify the branching a bit to allow the DB connection to only
be tested if the prefix is valid, and either way, we can then show a form
to send them back to. It doesn't even need to be a WP_Error object
, just something we can keep track of.
For both hidden elements and in the form inputs, we need to properly
escape these. We don't have access to esc_attr() here, so a call to
htmlspecialchars( $string, ENT_QUOTES ) sh
ould do. Rather than just doing this for the prefix. Also, always escape
as late as possible -- so in the form in both cases.
I think we're close. Nice work so far.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/15729#comment:6>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list