I need to call a function as such:
function something($argument1, $argument2, $data)
where $data can be any amount of variables comma separated: 1,2,3,4
so for instance I would call:
function something ('blue', 'green', 1,2,3)
or
function something ('red', 'black', 1,2,3,4,5,6,7,8,9)
I have looked into the ellipsis keyword (...) but I cannot see how I can implement this with my 2 static arguments ($argument1 and $argument2).
My intuition would be to put the comma separated into an array before calling the function and sending the array to the function?
Thanks!