I have two weblogs. Albums and Songs.
I have a relationship field in the Songs weblog that associates songs with albums.
I have a template “playlist” in template group “music”.
When linking to this template, I pass the url_title of the album as the third segment /music/playlist/album-name
I would then like to compare this segment, with the url_title from the related entries of each song to determine whether or not to show them.
I’m hoping I haven’t architected this entire setup incorrectly.
Any advice on how I can practically accomplish the equivalent of:
{if segment_3=={related_entries id="song_album"}{url_title}{/related_entries}}Any thoughts are appreciated.
Incidentally, just printing out the related_entries tag works fine, I’m presuming the if statement just doesn’t like a tag pair nested in there… tried assigning the value to a variable and comparing that without luck as well.