[ic] Interpolation of [item-] tags in an included file

Ron Phipps interchange-users@interchange.redhat.com
Wed Feb 6 06:04:00 2002


I'm building a "Recommend this item to a friend" component and ran into
a small snag.  The tags like [item-code], [item-field description], etc
do not interpolate inside the included file but all other tags do
properly.  The following line appears inside the [fly-list] tag in
flypage.html:

[include file="templates/components/recommend"]

I have also tried (I think include interpolates by default, unlike
file):

[include file="templates/components/recommend" interpolate=1]

Both result in the strings:

[item-code], [item-field description], etc being shown instead of the
actual values.

The content of recommend is:

[comment]
ui_component: recommend
ui_component_type: content, vertical
ui_component_group: promotion
ui_component_label: Recommend Item

[/comment]

<!-- BEGIN COMPONENT [control component recommend] -->

<br>Sku: [item-code]
<br>Title: [item-field description]
<br><br>

<!-- END COMPONENT [control component recommend] -->

I grepped for 'include' in the foundation demo and did not come up with
any components that use the [item-*] tags.  They all use an argument set
outside the component that is passed to a loop or query to return the
needed values.  Before I go this route I'd like to know if I'm trying to
do something that cannot be done due to the interpolation order.

I'm going to sleep on it and hopefully the answer will pop in my head in
the morning or someone here will have run into this before.  Thanks for
your help.

-Ron