[Petal] interpolate variable in metal:use-macro?

Corey corey_s at qwest.net
Mon Sep 25 22:29:22 BST 2006


Say I've got a variable stuffed into my template:

tmpl/macro

which would store a string, such as: "product1.html#content".

Now, I'd like to use what's in 'tmpl/macro' in order to include a metal macro,
like so:

<span metal:use-macro="tmpl/macro" petal:omit-tag="" />

... unfortunately, it doesn't look like tmpl/page is interpolating within the
'metal:use-macro=' ...

"[PETAL ERROR] Cannot find tmpl/macro in ......"


I'd really prefer to not have to do something like:

<span metal:use-macro="product1.html#content" petal:omit-tag="" />
<span metal:use-macro="product2.html#content" petal:omit-tag="" />
<span metal:use-macro="product3.html#content" petal:omit-tag="" />

etc.,etc.etc for each my, say, 10-30 products...

Am I missing something obvious?


Thanks!




More information about the Petal mailing list