$mainMenu[\'Home\'][1] = \'/mult/index.php\';
$mainMenu[\'Map\'][1] = \'/mult/kar.php\';
$mainMenu[\'MapA\'][2] = \'/mult/kara.php\';
$mainMenu[\'MapB\'][2] = \'/mul
You would need to nest two foreach BUT, there is nothing about your data structure that easily indicates what is a sub-item. Map vs. MapA? I guess a human could figure that out, but you'll have to write a lot of boilerlate for your script to sort that.. Consider restructuring your data so that it more closely matches what you are trying to achieve.
Here's an example. You can probably come up with a better system, though:
$mainMenu = array(
'Home' => '/mult/index.php',
'Map' => array(
'/mult/kar.php',
array(
'MapA' => '/mult/kara.php',
'MapB' => '/mult/karb.php'
)
),
'Contact' => '/mult/sni.php',
...
);