I am trying to get a value from a relationship field within a grid field. I have tried the suggestions on this site, but none are working for me.
so basically i have this:
{exp:channel:entries channel="series" orderby="date" sort="desc" limit="1" show_future_entries="no" status="open" category="45" } {!-- "series" contains the grid filed "lessons" --}
{lessons orderby="date" } {!-- This is my Grid --}
{lessons:title} {!-- Column in the Grid - Type: Text Input --}
{lessons:date format="%M %j, %Y"} {!-- Column in the Grid - Type: Date --}
{lessons:summary} {!-- Column in the Grid - Type: Textarea --}
{lessons:speaker} {!-- Column in the Grid - Type: Relationship --}
{/lessons}
{/exp:channel:entries}I can not get the value for speaker which is a relationship to a channel (short name “staff”), and i want the field value for “staff_first_name” that is populated from another multisite that we have up. I can assign values to it when publishing (it is a dropdown of values that have been put in from the other site). I have tried the following replacements for the {lessons:summary} line:
{lessons🔈staff_first_name} {lessons🔈staff:staff_first_name} {lessons🔈staff_first_name} {lessons🔈staff:title} {lessons:speaker} {staff:staff_first_name} {/lessons:speaker} {lessons:speaker} {speaker} {/lessons:speaker} {lessons:speaker} {staff_first_name} {/lessons:speaker}
None of the above have worked.
I just can not find anything online like what i want to do, and i would think it’s not that out of the ordinary since relationship is a type that you can use in grid.
I am wondering if multisite is somehow the problem. Although i have used that exact “staff_first_name” field as a relationship in another site that we have under the multisite umbrella. So i know i can access the values from site to site. But in that case i did not have the relationship within a grid, so it’s not helping me solve this one.
But i appreciate you reading over it and giving me some feedback!
Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.