I want to combined first 6 elements from two arrays.

I used following code to combined array.

```
$combined = array_combine($models,$prices);

```

This is the $models array

```
if (!is_null($elements)) {
    foreach ($elements as $element) {
        $nodes = $element->childNodes;
        foreach ($nodes as $node) {

            $modle = $node->nodeValue;
            $modle1 = basename($modle); 
            $models[] = $modle1;

        }
    }
}

```

This is the $prices array

```
if (!is_null($price)) {
  foreach ($price as $p) {

    $nodes1 = $p->childNodes;

    foreach ($nodes1 as $node1) {
      $modlePrice = trim($node1->nodeValue,'Regular Price:');
      $modlePrice1 = basename($modlePrice); 
      $prices[] = $modlePrice1;

    }
  }
}

```

Outputs of these arrays are :-
prices => LKR 295,000.00 LKR 395,000.00 LKR 290,000.00 LKR 150,000.00 LKR 68,000.00 LKR 45,000.00 LKR 31,000.00 LKR 340,000.00 

modles => Samsung 40" UA40 ES6220 Series 6 SMART 3D LED TV with 4 glasses
Samsung 55" F8000 Series 8 Smart 3D Full HD LED TV
Samsung 46" F8000 Series 8 Smart 3D Full HD LED TV
Samsung 40" F6400 Series 6 Smart 3D Full HD LED TV etc...

Can anyone help me.