Ignore unclosed BBcode tags


Currently this text:
this is a [i] a sample text
Becomes this (everything italic after [i]):
this is a a sample text

Is there a way to make the BBcode tags work only if there is a matching closing tag? I was looking in library/XenForo/BbCode/parser.php but did not find anything.
Last edited:


XenForo developer
Staff member
You'd have to change how the parser works, doing backtracking to change how the stack is handled when it comes to unclosed tags. It wouldn't be trivial.