Hi all,
I’ve searched through the API and this forum but can’t seem to find what I’m looking for, so any pointers or help would be appreciated!
In summary, I have a collection which amongst other things contains files (so each record has a field of field type document). I populate records with files gathered using a file upload button.
Elsewhere in my site I want to display files that have been uploaded - I want to display the file name and also link that file name to the file (so that clicking the name opens the file). However, the only way I can find to programmatically retrieve information about the file from the collection is to use:
$w( ‘#dataset1’ ).getCurrentItem().idDocument
(where idDocument is the field in the collection containing the files).
This returns something like:
wix:document://v1/fbe19f_7c55fe7332dd4fd389d6b316b43648b5.pdf/Dummy ID.pdf
I just want to show ‘Dummy ID.pdf’ on screen. And then to link that to the actual document.
Can anyone enlighten me how this can be achieved?
Many thanks in advance,
Michael