Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

laravel many to many relation update

$user->roles()->sync([1, 2, 3]);
Source by laravel.com #
 
PREVIOUS NEXT
Tagged: #laravel #relation #update
ADD COMMENT
Topic
Name
8+3 =