i use laravel 8 method for map key and join them with implode
it's work fine but i want joined value with link
my code :
{{$item->artists->map(function ($artist, $key) {
return $artist->title ;
})->implode('meta_value', ' , ')}}
it return somthing like : artist-1 , artist-2
but i want somthing like : <a href="artist-1">artist-1</a> , <a href="artist-2">artist-2</a>
thanks
My Answer:
>map(function($item, $key) {
return '' . $item->name . '';
})->implode(', ')}}
Rate this post
4 of 5 based on 5318 votesComments