i'm trying to write a function that changes HTML-code to a new markup-languange. Where br and /br is replaced by *. Although, after the first * (br) no whitespace is allowed and before the second * (/br) no whitespace is allowed. An example is given bellow.
Strong emphasis
• The start and end of a section with strong emphasis is defined by '*'.
• The starting * must not be followed by Whitespace. The ending * must not be preceded by Whitespace. As an example, * fat cat*, *fat cat * and * fat cat * are not permitted