Jump to content

Removing a $_SESSION entity if values = X


Freedom-n-Democrazy

Recommended Posts

Is there a way to make it How can I go about removing a $_SESSION entity if certain array values of it equal a specific value? I am thinking something along the lines of this:

 

if (isset($_SESSION['cart']['content'][$_POST['id']])) = array ('sizes' => 0, 'sizem' => 0, 'sizel' => 0, 'sizexl' => 0) {
// remove $_SESSION['cart']['content'][$_POST['id']]
}

Link to comment
https://forums.phpfreaks.com/topic/248965-removing-a-_session-entity-if-values-x/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.