[Pmwiki-users] <p> ..</p> instead of <p /> - handling contexts and	nested markup
    Bernhard.Weichel@t-online.de 
    Bernhard.Weichel
       
    Fri Aug  8 14:44:12 CDT 2003
    
    
  
Hi,
I am again in the problem to safely handle contextual markup. Some
Wiki-Markup might be rendered e.g. as Table, Which must be opened and closed
appropriately. Beginning of June, we had ad discussion that PmWiki should
even markup paragraphs as <p> contents </p> instead of <p /> contents. It is
somehow the same problem.
Patrick R. Michaud wrote (29.6.2003):
> There's a chance.  I started to render paragraphs as <p>text</p>
> instead of using <p /> but ran into a few complications so I went
> with what "worked"
> to get the 0.5.0 release finished and figured I could revisit it
> later if needed.
>
> So, I'll have to take a look at it and see what I can do.
At this time I proposed, that PmWiki offers a "context stack" which allows
to keep track of opened HTML-elements and perform an automatic close of
those.
Perhaps it makes sense to bring in some sort of context stack.
e.g.
  pushContext("table1", "<table>", "</table>")
  pushContext("tr")
  pushContext("td")
  pushContext("p")
  ....
  closeContext("table1")
A Wiki page should always maintain a pushcontext / closeContext sequence.
This would
keep page inclusions safe.
This would help customizers to easy maintain more complex markup.
The discussion vanished end of June, now I am running into the problem
again.
I could implement it as Plugin. But then I must be sure, that PmWiki always
outputs
matching HTML-Tags.
And I do not really know how to add the pushcontext/closecontext sequence
for pages without additional markup.
--Bernhard
    
    
More information about the pmwiki-users
mailing list