ZF-9473: parsing of incorrect tags

Issue Type: Improvement Created: 2010-03-18T14:14:20.000+0000 Last Updated: 2012-11-20T21:37:50.000+0000 Status: Open Fix version(s): Reporter: Konstantin.Myakshin (koc) Assignee: None Tags: - Zend_Markup

Related issues: Attachments:


<pre class="highlight">
$bbcode = Zend_Markup::factory('Bbcode');
$input = <<render($input);

/*string(135) "


    [*] 1[newline�] [*] 2[newline�] [*] 3[newline�][/list]
<strong>bold <strong>in</strong> bold</strong>



This is incorrect markup, I know =). But is it possible render it more correctly as now? h1 - inline tag, list - list: so close any inline tag when block/list found.

And can we replace double "strong" with single?


Posted by Konstantin.Myakshin (koc) on 2010-03-18T15:15:48.000+0000

  1. I think that need add groups (inline, block) as stroppers inside parser/bbcode $_tags var.

  2. And add options 'allowNesting' for tags

<pre class="highlight">
    'b' => array(
        'type'   => 10, // self::TYPE_REPLACE | self::TAG_NORMAL
        'tag'    => 'strong',
        'group'  => 'inline',
        'filter' => true,
        'allowNesting' => false

Have you found an issue?

See the Overview section for more details.


© 2006-2016 by Zend, a Rogue Wave Company. Made with by awesome contributors.

This website is built using zend-expressive and it runs on PHP 7.