On Sun, Oct 16, 2011 at 06:25:02PM +0200, Guillaume Turri wrote: > Hi, > > 2011/10/14 Chris G <[1]cl@xxxxxxxx> > > Is it possible to re-parse some code from within a syntax plugin? > > The hidden plugin[1] does it in two ways: > 1 - It parses the text in the first <hidden> tag. Here, it already has a > text to parse. It's done like this: > > $tab = array(); > > $parsedText = p_render('xhtml', p_get_instructions($rawText), $tab); > > I'm afraid it's not the most effective way to do it (like in "we're > launching a whole new parsing chain"); but it works. > > 2 - It lets parse the text between the <hidden> tags. It means in > particular that nested plugins may be used. > It's done thanks to the getAllowedTypes() and accepts() functions > Thanks, you've answered two of my E-Mails in one go! :-) As you say I think case 2 is the better option for what I'm trying to do. However I'm not quite clear *when* the text between the tags gets parsed relative to when my plugin is seeing it, I'll have to go and try some things out I think! -- Chris Green -- DokuWiki mailing list - more info at http://www.dokuwiki.org/mailinglist