hi...i have multi level menu
i want to make array and save 2 values on every click from menu so that i know on which link user clicked $name and $url in $cookies
using this code
<?php
$cookies = array();
// on click this function is calling
function addValue(){
global $cookies;
for ($i=0; $i<100; $i++) {
if (!isset($cookies[$i])) {
$id = $i;
$cookies = array('$name' => '$url ');
break;
}
}
setcookie("Cookie",$cookies,$sessionid);
}
my first menu is like this..and send name and url on click and one of this lick
ARTEMA
ASKAYNAK - KAYNAK TELLERİ
ASTRACAST- MUTFAK EVİYELERİ
FIRAT PLASTIK
GHIDINI - SİFONLAR
ORKA - BANYO DOLAPLARI
all of thm have sublinks
in upper part of page i want to show some thinng like this
home >> products >> artema >> ARTEMA AKSESUARLAR >>
how i make cookies and save link name and url?