Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

laravel collection implode

$collection = collect([
    ['account_id' => 1, 'product' => 'Desk'],
    ['account_id' => 2, 'product' => 'Chair'],
]);

$collection->implode('product', ', ');

// Desk, Chair
Source by laravel.com #
 
PREVIOUS NEXT
Tagged: #laravel #collection #implode
ADD COMMENT
Topic
Name
3+4 =