WordPress.org

Make WordPress Core

Opened 4 years ago

Last modified 7 weeks ago

#12760 assigned defect (bug)

Escaping shortcode conditionally — at Version 1

Reported by: pavelevap Owned by: markjaquith
Milestone: Future Release Priority: low
Severity: normal Version: 3.0
Component: Shortcodes Keywords: has-patch dev-feedback
Focuses: Cc:

Description (last modified by markjaquith)

Using additional brackets is the official way to "escape" a shortcode. e.g. [[escaped]]

Using additional brackets [[shortcode]] in a post works only when the plugin (function) for this shortcode is active. When deactivated, additional brackets are shown in the post. It is annoying for many users, because editors sometimes test a plugin, write about it in a post with shortcode example and after some months this plugin is deactivated. Now there will be additional brackets, breaking their example code.

Input:

[[shortcode_that_does_not_exist]]

Expected output, regardless of whether that plugin is active:

[shortcode_that_does_not_exist]

Actual output, if plugin is not active:

[[shortcode_that_does_not_exist]

[edited by Mark Jaquith]

Change History (2)

comment:1 markjaquith4 years ago

  • Description modified (diff)
  • Owner set to markjaquith
  • Status changed from new to assigned
  • Version changed from 2.9.2 to 3.0

kunalb4 years ago

Note: See TracTickets for help on using tickets.