From: niklas | brueckenschlaeger Date: 2010-11-19T04:54:29+09:00 Subject: Re: Session question --=-taLUyOSNEbDMw+RgZcEa Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable That entirely depends on what you put into the session. If you store a number: session[:cart] =3D 123 you can just set it to nil: session[:cart] =3D nil (or 0 or something...) If you store some array: session[:cart] ||=3D [] session[:cart] << 1 session[:cart] << 2 just delete from it: session[:cart].delete(1) session[:cart] #=3D> [2] After each request the data in the session object will be marshaled and stored, then loaded upon the next request. Hope that helps. On Thu, 2010-11-18 at 23:32 +0900, P=C3=A9ter Paudics wrote: > Hy all! >=20 > I'm working on a webshop and i create a session called cart for the Cart.= ( > session[:cart] ) > The session stores the quantities of the products in cart. >=20 > Please help me *how can i delete az item from the session*? (remove from > cart...) >=20 >=20 > Paudics P=C3=A9ter > Mail: papa019@gmail.com > Web: http://papa019.eu5.org --=-taLUyOSNEbDMw+RgZcEa Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iQIcBAABAgAGBQJM5YRuAAoJEIQdQGZOjo82/HUP/2qmEJ34DbCopcv1rQz8p911 sxGgGZ2gfSwT5O00znVYK41FyyUwT9HVBForNNdnfk/l4SFLh+Fj/eqA4MeZGHeL RpWZ6PBSxUA1dSi/eAeIxKJVL6DaRVKpwn15Wbqw7e+Qx/KUBrHN4QqgePqnRbwy 2kmMz4UzjpNrdbBbgXprq/55mcWXBFgf2chpfklynGIR9uO+cuN5IrOGqZaPuwVd 0VV9xaMCvsZkKlbwypYtbTazRRDbt0U+iQcyDXvgcyqPmymDoVJInu4ZyDtNoP1T oLF7L3voNuLSFgj+puvsqgpS6/pH6Jdy/aPmd1sJx0Na6oxFqolG7bQBF1O19IdQ TqjI4hiKvcnJZIs00ugIVg2yhY4iPTN7x1yeOoLfSdT+RQBL3j/ya69dOEn1EWqM /9/hVhpRGuhVodeimk6jaze2hI16dmzzIE74fT3+jXxKW1P75TfCY46yN16WOACk ZuRPuvRYW9zUUaMUOzNE87BLxtkif2f/MwM4FYabzQgH7POaHOe5WHwIWhlkXF8+ 7KJhNA+KNMr9/sX4QwPv6nARQdRDzayCB91vJfCV4TsynVAfYFHqCDYCTwmBvpQl y6TI1zkG5K23vxylyTphkRfRugNbWgMpD1NeYSG+TtCi0VP8R/O7M9fsxXzJOMQC zCEcA4yxz0mAk3JmwbfA =r7Dc -----END PGP SIGNATURE----- --=-taLUyOSNEbDMw+RgZcEa--