Join the Webstudio community

Updated 3 months ago

Accessing Airtable Lookup Fields

At a glance
Hey all,
Dabbling with a simple database.
I have got as far as getting items listed and can access most fields easily. The issue is when trying to do a lookup field, I'm stumped.
e.g.
I have cards showing posts.
I want to show the thumbnail for the authors.
I add a collection within each of the items I've created for the posts which pulls data from [Collection Item.fields.author] and its pulling the data fine (gibberish string for record ID).

Now the issue is I can't seem to access the data from that linked record.
Any suggestions?
Attachment
image.png
K
1 comment
Okay, manged to partially solve by instead just pulling the reference field.
e.g.
collection item.fields.["image from authors]
However,
I want to have the images LINK to a url from the reference.

e.g.
<a href=AUTHORLINK>
<img src=AUTHORIMG>
</a>

And I can only pull the data for one into the parent collection.
If I connect to the "Author" reference field all it pulls is the ids in the array e.g.
[array1, array2, array3]
But I can't find a way to pull data from there for the image and link.

Can anyone help?
Add a reply
Sign up and join the conversation on Discord