Make WordPress Core

Opened 14 years ago

Closed 14 years ago

#18765 closed defect (bug) (fixed)

tag_escape() should not strip digits

Reported by: sirzooro's profile sirzooro Owned by:
Milestone: 3.3 Priority: normal
Severity: normal Version: 3.2.1
Component: Formatting Keywords: has-patch
Focuses: Cc:

Description

tag_escape() strips digits, but it shouldn't - they are needed for <h1>..<h6> tags. Attached patch fixes this.

Attachments (1)

formatting.php.diff (410 bytes) - added by sirzooro 14 years ago.

Download all attachments as: .zip

Change History (5)

#1 @SergeyBiryukov
14 years ago

  • Milestone changed from Awaiting Review to 3.3

tag_escape() is only used in gallery_shortcode(), so the bug manifests if someone sets itemtag or captiontag attribute to one of the <h1>..<h6> tags. This seems like a rare situation, but still possible.

#2 @olleicua
14 years ago

Tested using revision 18784M and above formatting.php.diff. It works.

#3 @nacin
14 years ago

Realistically, 1-6 is the only required range. I haven't seen any specs for introducing more header tags. Unless, I guess, they're allowed in namespaced elements. Looks good.

#4 @ryan
14 years ago

  • Resolution set to fixed
  • Status changed from new to closed
Note: See TracTickets for help on using tickets.