Programmer Dude wrote:
"Paul N. Lee" wrote:
...I do my web pages the old fashioned way (by hand using Notepad),..
[bwg] And I thought *I* was macho because I do mine using vi (gvim, actually)!
Actually, using the vi Editor (along with the ex Editor) would make some things much easier than the old Win-95/98 Notepad. Especially when I need to do mass replacements. ;-} But after doing these since 1997 (going on six years), I can usually throw it together quicker than Scott's script can publish the web page (that is if I am online when Jim sends out the posting). :-)
A script that converts straight text to HTML should convert *all* "<", ">" and "&" to their HTML equivalents (>, < and &), because those are not legal HTML characters.
Yes, that would be the most logical approach. I tend to use the numerical equivalents: < > and & instead of the 'named' entities.
But if the input contains HTML, then I can see it getting pretty tough!
The FOTDs do not usually contain instances of HTML, but they have had many places where the greater-than and less-than symbols are used around specific values: <atan> <imag> And, then there are the formulae containing the greater-than and less-than symbols, such as: frm:MandelbrotBC1 { ; by several Fractint users e=p1, a=imag(p2)+100 p=real(p2)+PI q=2*PI*fn1(p/(2*PI)) r=real(p2)-q Z=C=Pixel: Z=log(Z) IF(imag(Z)>r) Z=Z+flip(2*PI) ENDIF Z=exp(e*(Z+flip(q)))+C |Z| <a } This is the one instance I recently had to go back and update several past FOTD web pages. A portion of the last line was not showing up on browsers. Sincerely, P.N.L. ------------------------------------------------- http://home.att.net/~Paul.N.Lee/PNL_Fractals.html http://www.Nahee.com/Fractals/