fork download
  1. <?php
  2.  
  3. $array = array(
  4. array('74','69'),
  5. array('45','1'),
  6. array('5','2'),
  7. array('88','3'),
  8. array('123.389,89', '12,33'),
  9. );
  10.  
  11. $arrayA = array();
  12. $arrayB = array();
  13.  
  14.  
  15. foreach ($array as $key => $value) {
  16. foreach ($value as $k => $v) {
  17.  
  18. if($k == 0) {
  19. array_push($arrayB, $v);
  20. } else {
  21. array_push($arrayA, $v);
  22. }
  23. }
  24. }
  25.  
  26. var_dump('<pre>',$arrayA,$arrayB);
Success #stdin #stdout 0.01s 82880KB
stdin
Standard input is empty
stdout
string(5) "<pre>"
array(5) {
  [0]=>
  string(2) "69"
  [1]=>
  string(1) "1"
  [2]=>
  string(1) "2"
  [3]=>
  string(1) "3"
  [4]=>
  string(5) "12,33"
}
array(5) {
  [0]=>
  string(2) "74"
  [1]=>
  string(2) "45"
  [2]=>
  string(1) "5"
  [3]=>
  string(2) "88"
  [4]=>
  string(10) "123.389,89"
}