MWDelaney / bootstrap-3-shortcodes

WordPress shortcodes for easier use of Bootstrap elements in your content.
https://wordpress.org/plugins/bootstrap-3-shortcodes/
MIT License
377 stars 118 forks source link

Nested columns not working #146

Closed aidan-doherty closed 7 years ago

aidan-doherty commented 7 years ago

I am trying to add code similar to the example on the bootstrap docs here but the short code is not formatting when nested items are added. The last close tags are just being rendered as Text example below.

[row]
  [column sm="9"]
    Level 1: .col-sm-9
       [row]
              [column sm="6" xs="8" ]
                Level 2: .col-xs-8 .col-sm-6
              [/column]
              [column sm="6" xs="8" ]
                Level 2: .col-xs-4 .col-sm-6
              [/column]
        [/row]
  [/column]
[/row]

On the frontend the closing shortcode is rendered:

Level 1: .col-sm-9 Level 2: .col-xs-8 .col-sm-6 Level 2: .col-xs-4 .col-sm-6 [/column] [/row]

MWDelaney commented 7 years ago

As discussed in #46, #63, and #86, WordPress doesn't allow nested shortcodes of the same name (see WordPress documentation here: https://codex.wordpress.org/Shortcode_API#Nested_Shortcodes). We've looked into supporting this (as noted in #86) but any solution we've found ultimately creates more clutter, and more documentation issues than we're prepared to deal with right now.