From: James Edward Gray II Date: 2005-09-27T09:03:57+09:00 Subject: Re: Embedded Ruby and Tag Libs On Sep 26, 2005, at 6:47 PM, Adam Van Den Hoven wrote: > The problem is that I LOVE XML, and find it easy to work with, > mostly because its easy to abstract complex things with it... which > is how I think. Oh well. I'm fine with it if with disagree on that. I really am only trying to help, not rob you of your favorite tool, I promise. ;) > Without thinking of MUCH better ways to do this, I submit the > following: > > > > > > > My offer to that would be similar to my last one, though I think this one is much easier: <%= person %w{name password single description} %> We don't have to do things the Rails' way. ;) I don't know about you, but I know which one of those I would rather be typing a lot of. I'll stop trying to convince you now though and see if I can't provide some information you would consider useful... > I'm assuming that whatever parser converts <%= ... %> in to ruby > code can just as easily be setup to do the same thing with tags No, I don't think ERb is going to meet your needs here. > , maybe using REXML (or what ever its called). It just needs to be > more precise. I really believe REXML is what you are looking for. Everything you have asked for is pretty easy with it. It will let you do all these transformations with a combination of XPath and Ruby which I assume you will find quite comfortable. You can learn more from the documentation: http://www.germane-software.com/software/rexml/docs/tutorial.html Hope that helps. James Edward Gray II