From: Dan Zwell Date: 2007-07-11T13:22:21+09:00 Subject: Re: Creating a language -- HTML + a few special tags Rob Hunter wrote: > Hi all, > > I'm looking to implement a "plug-in" language which is essentially just > HTML plus a few custom tags that I want to support. For example, some > source code in this language might look like > > > > where FOO and BAR are special tags that have some meaning that I define. > Say, for this example, that FOO strongs text inside a

tag, and BAR > emphasizes text inside a blink tag. So the "compiled down" source would > look like > >

> > Is there some open-source software that already does something like > this? Absent that, it seems like the best way is to just read in the > HTML with something like XmlSimple, write a simple interpreter to grovel > over the expression, evaluating the custom tags as they come up, and the > spitting out the resulting HTML. > > Thanks in advance for any advice! > > --rob > That sounds an awful lot like XML with XSL stylesheets... I don't know much about these, but I would start here http://www.w3schools.com/xsl/xsl_languages.asp if I wanted to learn. -Dan