[wp-trac] [WordPress Trac] #23279: Add templates to style registration, signup, activation, login and password reset pages

WordPress Trac noreply at wordpress.org
Sat Nov 23 07:06:06 UTC 2013


#23279: Add templates to style registration, signup, activation, login and password
reset pages
-------------------------+------------------------------
 Reporter:  rmccue       |       Owner:
     Type:  enhancement  |      Status:  new
 Priority:  normal       |   Milestone:  Awaiting Review
Component:  Themes       |     Version:
 Severity:  normal       |  Resolution:
 Keywords:               |
-------------------------+------------------------------

Comment (by rmccue):

 Phew, so, attachment:23279.diff contains my first run at this. It does the
 following:

 * Moves all the main HTML from `wp-login.php` to templates called
 `core/login.php`, `core/register.php`, `core/resetpassword.php` and
 `core/retrievepassword.php` (Considering using `wp/` here instead, as
 `core/` might conflict easily.)
 * Adds default fallback templates in `wp-includes/theme-compat/` with the
 same ol' HTML as always.
 * Adds the `login_locate_template` function to extend `locate_template`
 with the theme-compat check. (This could go into a non-`login_`-namespaced
 function if we'd prefer; something like `wp_locate_core_template`)
 * Adds a `resetpassword_form` hook to match the other `*_form` filters.
 * Moves hidden fields from the templates to a function hooked into
 `login_form`, `register_form`, `lostpassword_form`, and
 `resetpassword_form`. (This currently uses a single function with a switch
 to avoid having 4 functions, but I'm easy on this.)
 * Adds a `login_register_link` function to link to the registration form
 if it's enabled (along with `$before` and `$after` parameters to
 prepend/append content)
 * Reformats some of the inline Javascript on the login form.

 Comments very welcome. At the moment, the header/footer content is still
 locked into `login_header` and `login_footer`, so it's possible we want
 that moved to a template as well. If so, we should probably use
 `wp/login/*` (with `wp/login/header.php` and `wp/login/footer.php`) there
 to make it clear.

 Note that I also didn't touch successful authentication with interim
 logins, as it's basically just `login_header` then `login_footer`. Happy
 to move that too.

--
Ticket URL: <http://core.trac.wordpress.org/ticket/23279#comment:7>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list