• remove br tags near list tags

    By John Smart 1 decade ago

    Change WikiPage.parseParas to:


    Private Function parseParas (txt As String) As String<br/>
        '** replace double linefeeds with &lt;p&gt;, single ones with &lt;br&gt;<br/>
        parseParas = Replace(txt, Chr(10) &amp; Chr(10), &quot;&lt;p&gt;&quot;)<br/>
        parseParas = Replace(parseParas, Chr(10), &quot;&lt;br&gt;&quot;)<br/>
        <br/>
        '** special case where &lt;/h3&gt;&lt;br&gt; adds too much line spacing<br/>
        parseParas = Replace(parseParas, &quot;&lt;/h3&gt;&lt;br&gt;&quot;, &quot;&lt;/h3&gt;&quot;)<br/>
        parseParas = Replace(parseParas, &quot;&lt;/h4&gt;&lt;br&gt;&quot;, &quot;&lt;/h4&gt;&quot;)<br/>
        parseParas = Replace(parseParas, &quot;&lt;br&gt;&lt;li&gt;&quot;, &quot;&lt;li&gt;&quot;)<br/>
        parseParas = Replace(parseParas, &quot;&lt;/li&gt;&lt;br&gt;&quot;, &quot;&lt;/li&gt;&quot;)<br/>
        parseParas = Replace(parseParas, &quot;&lt;/ol&gt;&lt;br&gt;&quot;, &quot;&lt;/ol&gt;&quot;)<br/>
    End Function<br/>