SessionHandlerInterface::destroy PHP Method

destroy() public method

public destroy ( $session_id )
    public function destroy($session_id);

Usage Example

Ejemplo n.º 1
0
 public function testWriteSession()
 {
     $sessionId = sha1(uniqid());
     // write
     $this->adapter->write($sessionId, serialize(['hello' => 'world', 'what' => 'um..']));
     // then data
     $this->assertEquals(['hello' => 'world', 'what' => 'um..'], unserialize($this->adapter->read($sessionId)));
     // destroy
     $this->adapter->destroy($sessionId);
     // then blank
     $this->assertEquals('', $this->adapter->read($sessionId));
 }
All Usage Examples Of SessionHandlerInterface::destroy