<?php

function product($x1, $x2) {
  $result = array();
  foreach ($x1 as $key1 => $value1)
    foreach ($x2 as $key2 => $value2)
      $result[$key1][$key2] = array($value1, $value2);
  return $result;
}

function print_product($x) {
  $tmp = array();
  foreach($x as $row) {
    $tmp = array_merge($tmp, array_map(function($value){
      return implode('-', $value);
    }, $row));
  }
  return $tmp;
}

$items = array('palto','noski','shapki');
$colors = array('red','black','white');
$materials = array('kozha','meh','aluminij');

echo implode("<br/>\n", 
  print_product(product(
    print_product(product(
      $items, 
      $colors
    )), 
    $materials)
  ));