3

I’m having an issue getting my Playa fields to render properly inside of a {exp:zoo_visitor:details} tag.

{exp:channel:entries
 channel="implementation_notes"
 disable="categories|category_fields|member_data|pagination|trackbacks"
 dynamic="off"
 search:implementation_note_segment="{embed:segment_entry_id}"
 author_id="NOT_CURRENT_USER"
}
<div class="implementation-note">
 <header>
  {exp:zoo_visitor:details member_id="{author_id}"}
   <p>{school}{title}{/school}</p>
   <p><b>Classes</b>: {visitor:member_classes}{class}{title}{/class}, {grade_level:label}{/visitor:member_classes}</p>
  {/exp:zoo_visitor:details}
  <p class="time">{entry_date format="%l, %F %j, %Y at %g:%i %a"}</p>
 </header>

</div>
{/exp:channel:entries}

The fields {school} and {class} are not rendering the title for the Playa children, but rather the title of the current implementation_note channel entry. If I try adding visitor: to the playa field, I get the exact same issue. I can get the data as it’s presented in the field in the db by using just the field name, but that gives me the usual Playa string of information that is unusable on the front end.

This is already inside of one embed, I’d really rather not make a separate embed for these children. Am I crazy, and just missing something simple here?

2

It looks like the problem here is that {exp:zoo_visitor:details} is actually a channel entry unto itself. I placed it inside of its own embed, and it worked like magic. The next step is going to be getting it out of this embed and into a Stash template.

The other problem that I had was simple user error. I forgot that {school} was actually {member_school}. Oy.

| improve this answer | |
0

I don't use Playa very much but don't you have to use the {exp:playa:children} tag?

  {exp:playa:children field="school"}
    {title}
  {/exp:playa:children}

Playa Docs:
http://pixelandtonic.com/playa/docs/templates#playa:children


If you are sure the tags are correct, try adding parse="inward" parameter to your zoo_visitor or Playa tag.

| improve this answer | |
  • Unfortunately, parse="inward" does nothing here. I'm hoping I'll get a response from EE Zoo on this one. :( – Christopher Kennedy Dec 9 '12 at 23:44
  • Just so I'm clear, the Playa tags parse correctly outside the Zoo Visitor tag but not inside the tag? – Anna_MediaGirl Dec 10 '12 at 4:38
  • Yup, you got it. It's not functioning inside Zoo Visitor, even without parse="inward". :( – Christopher Kennedy Dec 10 '12 at 7:37
  • Might try parse="outward" on the Zoo tag just to be thorough. – Anna_MediaGirl Dec 10 '12 at 7:43
  • Unfortunately, that too, didn't work. Hopefully EE Zoo will have an answer that I can post here later. Blergh. – Christopher Kennedy Dec 10 '12 at 7:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.