Opened 13 years ago
Last modified 7 years ago
#24846 reopened defect (bug)
Usage of a shortcode disables wpautop filter
| Reported by: | Looimaster | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | Formatting | Version: | 3.6 |
| Severity: | normal | Keywords: | wpautop |
| Cc: | Focuses: |
Description
In WP3.6 RC1 when I do this:
Some text. Some text. Some text. Some text. Some text. Some text. Some text.
it works just fine. It creates a paragraph.
But when I do this (both in "Visual" and "Text" editors):
[symple_highlight color="gray"]Some text[/symple_highlight]. Some text. Some text. Some text. Some text. Some text. Some text.
it doesn't wrap the text in anything. Paragraph is skipped.
The plugin that was used: http://www.wpexplorer.com/symple-shortcodes/ (but I bet it isn't plugin's bug).
Change History (9)
#2
@
13 years ago
- Milestone Awaiting Review
Sadly the plugin is only available for members. There isn't much we can do here.
#3
@
13 years ago
Here's the shortcode:
function symple_highlight_shortcode( $atts, $content = null ) {
extract( shortcode_atts( array(
'color' => 'yellow',
'class' => '',
),
$atts ) );
return '<span class="symple-highlight symple-highlight-'. $color .' '. $class .'">' . do_shortcode( $content ) . '</span>';
}
add_shortcode('symple_highlight', 'symple_highlight_shortcode');
This creates a paragraph:
Some text. Some text. Some text. Some text. Some text. Some text. Some text.
This creates a paragraph:
Some text. Some text. Some text. [symple_highlight color="gray"]Some text[/symple_highlight]. Some text. Some text. Some text.
This doesn't create a paragraph:
[symple_highlight color="gray"]Some text[/symple_highlight]. Some text. Some text. Some text. Some text. Some text. Some text.
Please note that paragraph is actually created, but after the text:
#6
@
13 years ago
Looimaster: Instead of investigating the output in the Chrome Dev Tools, what does it say in the real HTML source of the page?
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)

Tested against trunk rev 24833 using simple custom shortcode as demonstrated on codex (http://codex.wordpress.org/Shortcode_API).
Shortcode did not disable or interrupt
wpautopfilter from working correctly.Closing as invalid, most likely this is an issue with the Looimaster's Symple Shortcodes plugin.