Skip to content

Commit

Permalink
Docs: Correct documentation for the_password_form hook.
Browse files Browse the repository at this point in the history
This replaces an outdated note about the 20 characters limit on the password field in the WordPress database schema.

The `post_password` column was increased to 255 characters in WordPress 4.7.

Follow-up to [27676], [38590].

Props debarghyabanerjee, peterwilsoncc, dd32, mukesh27.
Fixes #61703.

git-svn-id: https://develop.svn.wordpress.org/trunk@58846 602fd350-edb4-49c9-b593-d223f7449a82
  • Loading branch information
SergeyBiryukov committed Aug 3, 2024
1 parent bdef9de commit e4b3f44
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/wp-includes/post-template.php
Original file line number Diff line number Diff line change
Expand Up @@ -1777,9 +1777,10 @@ function get_the_password_form( $post = 0 ) {
/**
* Filters the HTML output for the protected post password form.
*
* If modifying the password field, please note that the core database schema
* limits the password field to 20 characters regardless of the value of the
* size attribute in the form input.
* If modifying the password field, please note that the WordPress database schema
* limits the password field to 255 characters regardless of the value of the
* `minlength` or `maxlength` attributes or other validation that may be added to
* the input.
*
* @since 2.7.0
* @since 5.8.0 Added the `$post` parameter.
Expand Down

0 comments on commit e4b3f44

Please sign in to comment.