On my Resources page, I have a collection list of Resources, the link block of which I’d like to link to either a URL or a file. How do I get my link block’s link to pull from EITHER a link field or a file upload field? Thoughts?
You design a block containing, side by side, both elements. The one composed of a link block to a URL and the same one but with the link block linking to the file.
Then you use Conditional visibility to only show blocks when their respective field “is set”. I assume you won’t have items with both the file link AND the page link, right?
Thanks @Vincent, makes sense, but doing it that way I can’t control the sort order. I ended up moving it into a non-link block div, and using 2 separate full-width/full-height, absolutely-positioned link divs, assigning one to the Link field and one to the File field and setting conditional visibility on them, then making sure to let Editors know through the Help Text field in the CMS to use one or the other, but not both.
Ah yes the overlay link is a great way too!