hi there,
i have a two arrays
variable $isect is the intersection point.
I want to split the arrays into smaller arrays when intersection point is reached.
So far i’ve came up with this:
$isect=array_intersect_key($key,$tdc);
$num=$isect[1]-$isect[0];
$test3=array_slice($tdc,$isect[0],$num);
$num=$isect[2]-$isect[1];
$test4=array_slice($tdc,$isect[1],$num);
How to loop through this piece of code ?
[QUOTE=JohansonevR;4522846]hi there,
i have a two arrays
variable $isect is the intersection point.
I want to split the arrays into smaller arrays when intersection point is reached.
So far i’ve came up with this:
How to loop through this piece of code ?
$isect=array_intersect_key($key,$tdc);
$num=$isect[1]-$isect[0];
$test3=array_slice($tdc,$isect[0],$num);
$num=$isect[2]-$isect[1];
$test4=array_slice($tdc,$isect[1],$num);
PS. I’ve misclicked the reply button may i be excused
I think I know what you want, but I’d rather not make assumptions. Why don’t you provide some sample values for $key, $tdc, and the resulting $test array.