[Date Index][Thread Index]
[Date Prev][Date Next][Thread Prev][Thread Next]

Re: showing comments in HTML



>If you prefer modifying input lines, i suggest
>    s/^\([ 	]*\)#/\1\#/
>          ^^ space and tab

 This is the best Idea. I think it is better to use "\#" than wasting
 my time with "#" this makes my source pretty ugly.

 Anyway, if somebody is interested in, I make a `private' <verbatim>
 that changes all '&' to '&amp;' but keeps the entities (&...;)
 working.

 Probably it has no really use, but if somebody likes to try it:

<define-container verbatim>
<pre>\
{:\
    [[s|&(?!\S+;)|&amp;|sg]]\
    [[s|<|&lt;|sg]]\
    [[s|>|&gt;|sg]]\
    [[s|\n+\s*$||s]]\
    %body\
:}\
</pre>\
</define-container>

 The trick is just the (?!\S+;). I am just learning Perl Regular
 Expresions O:-) 

-- 
Saudos:
><ose        xmanoel@bigfoot.com   (Vigo/Galicia/Espaņa)
         http://pagina.de/xmanoel/
         http://w3.to/mikkeli/

10/14	British Computer Society founded, 1957
10/14	Frump Day. 
10/14	(10/14/1890) Dwight David Eisenhower, 34th president. 
______________________________________________________________________
Website META Language (WML)                www.engelschall.com/sw/wml/
Official Support Mailing List                   sw-wml@engelschall.com
Automated List Manager                       majordomo@engelschall.com