[wp-trac] [WordPress Trac] #58226: HTML attribute "action" on element "form": Must be non-empty.

WordPress Trac noreply at wordpress.org
Mon Oct 16 00:21:27 UTC 2023


#58226: HTML attribute "action" on element "form": Must be non-empty.
-------------------------------------------------+-------------------------
 Reporter:  Malae                                |       Owner:  joedolson
     Type:  defect (bug)                         |      Status:  accepted
 Priority:  normal                               |   Milestone:  6.4
Component:  Login and Registration               |     Version:  5.9
 Severity:  normal                               |  Resolution:
 Keywords:  dev-feedback has-patch needs-        |     Focuses:  coding-
  testing has-testing-info                       |  standards
-------------------------------------------------+-------------------------

Comment (by peterwilsoncc):

 Setting the action to `site_url( 'wp-login.php' )` or `wp_login_form()`
 will remove the redirect destination for the login, ie the `redirect_to`
 query string parameter. On the reset password page, it will return users
 to the login form.

 Rather than populate the `action` attribute, I suggest it be removed as
 the default value is to use [https://developer.mozilla.org/en-
 US/docs/Learn/Forms/Sending_and_retrieving_form_data the current URL].
 This approach passes when run through validator.w3.org.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/58226#comment:14>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list