Nosto / techdocs

2 stars 2 forks source link

Can you provide an example of how to fetch custom fields in templates? #18

Closed StanislavKraus closed 6 years ago

StanislavKraus commented 6 years ago

So far, we only have examples of of product.getCustomFields('key') in Slack but nowhere in our documentation. That might be added here: https://github.com/Nosto/docs-nosto-com/wiki/Product-Tagging#tagging-the-tags-andor-custom-fields

KonstantinDerEntwirrer commented 6 years ago

When tagging is

  <span class="custom_fields">
  <span class="material">Cotton</span>
  <span class="weather">Summer</span>

variable would be $product.getCustomField('material') $product.getCustomField('weather')

Output would be Cotton Summer

ValterAndersson commented 6 years ago

Currently we don't cover templating at all in this repository, but we need another place to cover these topics definitely. Will bring this topic up.