[Zope] DTML equiv of eval (again).

chas panda@skinnyhippo.com
Sun, 03 Oct 1999 05:39:07 +0800


Just when I thought I understood how to use _['var' + x] as
an equivalent of eval() within DTML, this one trips me up :

/index_html
/Images
	/imgDogs
	/imgCats

why does this work :
<dtml-with Images>
	<dtml-var "_['img' +  x]">
</dtml-with>
where x = 'Dogs'

But this does not : 
<dtml-var "_['Images.img' +  x]">

I've checked and this certainly would have worked :
<dtml-var "Images.imgDog"> 

Thanks,

chas