Submitted by : simon at: 2003-10-26T21:31:33+00:00 (14 years ago)
Name :
Category : Severity : Status :
Optional subject :  
Optional comment :

This is the old zope DTML bug which the infamous antidecap kludge was introduced to work around. I think I was wrong to believe this fixed in zope 2.4. Re-enabling the kludge for all zope versions, as of zwiki 0.9.10.


Simon, 2002/05/11 22:21 GMT (via web):
update:
           # DTML's decapitate() moves an initial block of lines that 
            # include : into the HTTP header
            # workaround: keep a comment in front to hide them, strip it
            # everywhere else (_set_text, read, ...).
            #if ZOPEVERSION < (2,4):
            #    t = '<!--antidecapitationkludge-->\n\n' + t
            #else:
            #    pass
            # I thought this had been fixed in zope 2.4, but no longer
            # furthermore, the old kludge no longer seems to be enough
            # NB saving page text in the ZMI strips a leading blank line,
            # including an invisible one that can prevent the above
            # try this variant
            #t = '\n<!--antidecapitationkludge-->\n\n' + t
            # nope, no good
            # I give up :(. It's not worth my while to figure this out.


Simon, 2002/05/13 20:07 GMT (via web):
NB this bug affects only the structuredtextdtml and htmldtml page types in zwiki versions <= 0.9.9, and the dtmlstructuredtext page type in zwiki >= 0.9.10.