Is there some practical way to define new tags and have them
substituted to code by a preprocessor? What I'm looking for is something
pretty similar to what in C would be:
#define <math> <?plugin TeX2png text="$$
#define </math> $$" ?>
So when someone writes:
<math>x^2</math>
it's preprocessed and translated to:
<?plugin TeX2png text="$$y^2+x$$" ?>
before being processed by the wiki. I think it would clean the syntax
and ease some repetitive tasks.
It seems that there's no support at all for it, and I'm willing
to implement it, but I need a bit of help to find myself around the
code. I suppose this code would go into BlockParser.php, perhaps at
_getBlock?
Any ideas or suggestions are appreciated.
--
Bruno Barberi Gnecco <brunobg_at_users.sourceforge.net>
http://www.lsi.usp.br/~brunobg/
Never worry about theory as long as the
machinery does what it's supposed to do.
-- R.A. Heinlein
|