My repeater image is currently linked to my dynamic page and when clicked, it opens the page in the same window. What I am trying to achieve is when user clicks the image it opens the dynamic page in a new window. How do I go about achieving this?
This is my code but when I click it open a new tab but it shows the error that page not found and URL like this : https://orooms.in/home-profile/undefined%7D
$w("#repeater1").onItemReady( ($w, itemData, index) => { $w("#image1").link = `https://orooms.in/home-profile/${itemData.HouseID}}`; $w("#image1").target = "_blank"; } )
me too, anyone?
Im facing the same problem and Im stuck
Were you ever able to figure this out? I'm trying to do the exact same thing. The problem I'm running into is that I don't know how to construct the url as external while still using the field ID from my data.
Code that works:
$item("#thumbnail").link = itemData['link-EventPhotos-relatedjob'];
Code that doesn't work:
$item("#thumbnail").link = 'https://propshop.com/${itemData[link-EventPhotos-relatedjob]}'
Thank you!!!
make sure you use the correct field key from `itemData`. See here: https://support.wix.com/en/article/about-your-database-collection-fields#regular-fields