/ / correct, single $$cart - items = array( "10 "= 1); / / invalid, because $cart - $items becomes $cart -" "$cart - $items = array("10" = 1); / / correct, but may or may not be what was intended: / / $cart - $myvar becomes $cart - items $myvar = 'items'; $cart - $myvar = array("10 "= 1);
?php / / correct, $unique $cart - items = array( "10 "= 1); / / incorrect, car $cart - $items devient $cart -" "$cart - $items = array("10" = 1); / / correct, mais risque de ne pas se comporter comme prévu / / $cart - $myvar devient $ncart - items $myvar = 'items'; $cart - $myvar = array("10 "= 1);?