WordPress.org

Make WordPress Core

Opened 5 years ago

Closed 5 years ago

#29515 closed defect (bug) (duplicate)

Escape/encode some HTML tags used in core docblocks

Reported by: DrewAPicture Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: General Keywords: has-patch
Focuses: docs Cc:
PR Number:

Description

In some function references, such as get_media_embedded_in_content we reference specific HTML tags like <video>, <audio>, <embed>, <iframe>, or others.

And since markdown backslash escaping doesn't apply to greater- and less-than characters, we may need to encode them directly in the docblocks so they can be properly parsed for the Code Reference.

Attachments (1)

29515.diff (445 bytes) - added by DrewAPicture 5 years ago.

Download all attachments as: .zip

Change History (3)

@DrewAPicture
5 years ago

#1 @DrewAPicture
5 years ago

The other obvious choice may be to run esc_html() on the parser side before it goes through markdown parsing. We'll have to figure out what works best across the board.

#2 @kpdesign
5 years ago

  • Milestone Future Release deleted
  • Resolution set to duplicate
  • Status changed from new to closed

Duplicate of #30473.

Note: See TracTickets for help on using tickets.