From: Sean O'Dell Date: 2004-06-23T11:13:48+09:00 Subject: Re: [ANN] cs/Template 0.1.2 On Tuesday 22 June 2004 17:43, eckelmann wrote: > Hi, > > very nice template library! I like it because the syntax is xml agnostic > (one thing that turns off of Amrita). I like because it is fast! > > Having the ${eval ...} macro is a fine thing, but how can I access the > template data from the eval'd ruby code? Can I even change the data in > an eval block? You can make the template object a class @@variable, instance @variable or a global $variable and then you have access to it, and the template#data method, or you can call template#resolve to use paths to get at your data. Perhaps I can figure out how to call the eval in the context of the template itself so ${eval} always has access to @data. Sean O'Dell