I'm using .getcurrentItem(); to pull through a product onto my page. I'm trying to pull through 3 Additional Info Sections but can't work out the next step.
Any help would be appreciated.
Important forum update
This forum is migrating to one unified Wix community forum starting July 26th, and will be read-only during the process.
Wishlist Page is the official platform for requesting new features. You can vote, comment, and track the status of the requested features.
Hi,
The Additional info is Array of Object so to access to it you can use the following example code:
let product = $w('#dataset2').getCurrentItem() let ArrayAdditionaInfo = [] ArrayAdditionaInfo = product.additionalInfoSections ArrayAdditionaInfo.forEach((element) => { console.log(element) console.log(element.title) console.log(element.description) })
good luck, Erez
Hi,
The Additional info is Array of Object so to access to it you can use the following example code:
let product = $w('#dataset2').getCurrentItem() let ArrayAdditionaInfo = [] ArrayAdditionaInfo = product.additionalInfoSections ArrayAdditionaInfo.forEach((element) => { console.log(element) console.log(element.title) console.log(element.description) })
good luck, Erez