Replies: 2 comments 2 replies
-
Closest I've come to a solution is this: Statamic::tag('collection:blocks')->param('id:contains', $block->fileData()['block_link'])->fetch() But that seems a bit convoluted, and if that is to work I have to remove the
|
Beta Was this translation helpful? Give feedback.
0 replies
-
I think you should be able to simply do |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I've been eyeing the link tag (https://statamic.dev/tags/link). In my blueprint I've added the
link
field and linked it another collection item.I'm trying to link to a section on the same page with an anchor link as in:
<a href="#services">Services</a>
where the anchor link is the slug of the linked entry.This is what
$block->fileData()
prints:When I do
{{ $block->link }}
it prints nothing.I'm probably missing something! Any ideas?
Beta Was this translation helpful? Give feedback.
All reactions