Developer forum

Forum » Ecommerce - Standard features » Ecom product list template - problem when using TemplateTags

Ecom product list template - problem when using TemplateTags

René Poulsen
René Poulsen
Reply

Hi,

I've got a problem with an ecom productlist template, where I want to use TemplateTags() on the product. Without TemplateTags everything is rendered just fine - but with TemplateTags it's as if there are no products.

My template is pretty simple:
<section class="section">
    <div class="content">
        @foreach (var product in GetLoop("Products")) {
            <div id="test" domflag>@product.GetString("Ecom:Product.Name")</div>
        }
    </div>
</section>

 

If I add <div>product.TemplateTags()</div> inside the loop, nothing is rendered. If I add <div>@TemplateTags()</div> outside the loop I just get these info. So there's no product loop, no nothing :-)

Template:BaseUrl System.String /Files/Templates/Designs/.../eCom/Productlist/
Template:DesignBaseUrl System.String /Files/Templates/Designs/.../
Loops

Has anyone experienced this and got a fix for it?

 

 


Replies

 
René Poulsen
René Poulsen
Reply

?

 
Lars Larsen
Lars Larsen
Reply

Hi René

Can't reproduce it on DW9.5.3. What version do you use?

 
René Poulsen
René Poulsen
Reply

9.5.0.

 
Nicolai Pedersen
Reply

Still a problem. Contact support with a link to the solution and the entire template.

BR Nicolai

 
René Poulsen
René Poulsen
Reply

Done :-)

 
René Poulsen
René Poulsen
Reply

Solved: When adding the eCom module to a paragraph, the "List feed" template is automatically set to a template that in my case didn't exist. With theese settings the TemplateTags() inside the loop didn't work. When setting the "List feed" to "Nothing selected", the template tags indside the loop works just fine.

 

You must be logged in to post in the forum