Opened 11 years ago
Closed 11 years ago
#27071 closed defect (bug) (fixed)
Invalid HTML produced by get_the_password_form
Reported by: | andykeith | Owned by: | SergeyBiryukov |
---|---|---|---|
Milestone: | 3.8.2 | Priority: | normal |
Severity: | normal | Version: | 3.7 |
Component: | Posts, Post Types | Keywords: | has-patch commit fixed-major needs-unit-tests |
Focuses: | Cc: |
Description
There seems to be a bug with the HTML returned by get_the_password_form (post-template.php). There's a line break between lines 1251 and 1252 (the closing </p> tag surrounding the input and the closing </form> tag). This causes an extra </p> to be generated by the browser. So the output on a password-proteced post looks like this:
<form action="http://localhost/themedev/wp-login.php?action=postpass" class="post-password-form" method="post"> <p>This content is password protected. To view it please enter your password below:</p> <p><label for="pwbox-611">Password: <input name="post_password" id="pwbox-611" type="password" size="20" /></label> <input type="submit" name="Submit" value="Submit" /></p> </p></form>
Simple fix - just need to remove this line break and it works fine.
Attachments (1)
Change History (6)
#1
@
11 years ago
- Keywords has-patch commit added
- Milestone changed from Awaiting Review to 3.9
- Version changed from 3.8.1 to 3.7
#2
@
11 years ago
- Owner set to SergeyBiryukov
- Resolution set to fixed
- Status changed from new to closed
In 27134:
Note: See
TracTickets for help on using
tickets.
Confirmed. It's not the line break, it's the extra tab. [25010] accidentally reverted [21124] and reintroduced #21018.
We should probably look into
wpautop()
(see ticket:21018:1 and ticket:21018:21018.diff), but at least let's fix the regression here.