Couple things seems to not be correct. First it sounds like you want a many-to-many relationship. That would make it
return $this->belongsToMany('Tiles\TileTag');
Second. This line doesn't make sense
<li class="col-md-4 mix" data-category="{{ $tile->tags->tag_title }}">
isn't $tile->tags a collection? So you would need to iterate over it.
foreach ($tile->tags as $tag) {
//
}
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community