Display content of one specific field from a collection on button click

Hey there, i got a simple problem but i am not able to figure out how to solve it. I read the documentation several times but i didn´t helped me to fix it so maybe somebody got an advice for me?

I got two different buttons and a text field. In addition to that there is a dataset/collection filled in with titles and texts. If button 1 is clicked the textbox should show “text1”. If button 2 is clicked the textbox should show “text2”. I understand that i have to connect the data from the dataset/collection to the text-element via Wix Code. But how can i do that?

Thanks a lot for any kind of help!
Marian

1 Like

https://support.wix.com/en/the-wix-editor/button
https://www.youtube.com/watch?v=1p-fRkLWyMs
https://www.wix.com/code/reference/$w.HiddenMixin.html#show
https://www.wix.com/code/reference/$w.HiddenMixin.html#hide
https://www.wix.com/code/home/example/Hide-and-Show-Elements
https://support.wix.com/en/article/wix-code-tutorial-displaying-database-content-on-a-regular-page
https://support.wix.com/en/article/about-connecting-page-elements-to-database-content