no save
Assistance
Achat
News

Forum | webmastering
[PHP] afficher avec une boucle un array
okuni, le sam. 29 nov. 2008 à 15:47:32
Bonjour,

Je suis en train de créer un panier virtuel pour mon site et j'aimerais savoir comment faire pour afficher tout le panier virtuel.
Il est construit dans un array en session comme suit :
/* Initialisation du panier */
$_SESSION['panier'] = array();
/* Subdivision du panier */
$_SESSION['panier']['id_produit'] = array();
$_SESSION['panier']['nom_produit'] = array();
$_SESSION['panier']['quantite'] = array();
$_SESSION['panier']['taille'] = array();
$_SESSION['panier']['couleur'] = array();
$_SESSION['panier']['prix'] = array();
Sur une page, j'aimerais donc afficher tout le contenu de l'array à l'aide d'un while sauf que je ne sais pas quoi mettre comme condition pour le while.

Quelqu'un sait m'aider?
--
L'amour, c'est comme les spaghettis; quand c'est mou, c'est cuit. (proverbe belge)


giheller
nov. 08
Suivant
REPONSES
giheller
nov. 08
okuni
nov. 08
giheller
nov. 08
Alain_42
nov. 08
giheller
nov. 08
okuni
nov. 08
Alain_42
nov. 08
okuni
nov. 08
Version Web
Réalisé par RedShift
no save