Antler enabled field value on Blade template #8696
-
I have a field which needs to pass title as variable which is antlers enabled. I want to use the parsed value in a blade template, how can I achieve it. content: 'Hi! Welcome to {{ $title }}' I am querying this entry using $path = $request->path();
$entry = Entry::query()
->where('uri', "/" . $path)
->first(); and in blade template <h3> {{ $entry->content }} </h3> but Its giving me raw value without rendering value for variable title Output <h3>Hi! Welcome to {{ $title }}</h3> |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 4 replies
-
Hmm, we have a "parse Antlers" setting on all fields to allow variables to be used in content, but I don't think that feature exists for Blade. Can you enable that setting in your blueprint and then try an Antlers template (even a partial will work with a regular @include()` and see if it works as expected there? |
Beta Was this translation helpful? Give feedback.
-
Looks like this is a known issue: #8430 |
Beta Was this translation helpful? Give feedback.
You should be able to do something like
$entry->blueprint()->fields()->get($your_field_handle)->config('antlers')