Database

Extends \Joomla\Session\Storage

Database session storage handler for PHP

deprecated
link

https://secure.php.net/manual/en/function.session-set-save-handler.php

since

1.0

deprecated

2.0 The Storage class chain will be removed

Methods

__construct

Constructor

__construct(array $options = array()) 
inherited deprecated
since

1.0

deprecated

2.0

Arguments

$options

arrayOptional parameters.

close

Close the SessionHandler backend.

close() : boolean
inherited deprecated
since

1.0

deprecated

2.0

Response

booleanTrue on success, false otherwise.

destroy

Destroy the data for a particular session identifier in the SessionHandler backend.

destroy(string $id) : boolean
inherited deprecated
since

1.0

deprecated

2.0

Arguments

$id

stringThe session identifier.

Response

booleanTrue on success, false otherwise.

gc

Garbage collect stale sessions from the SessionHandler backend.

gc(integer $maxlifetime = null) : boolean
inherited deprecated
since

1.0

deprecated

2.0

Arguments

$maxlifetime

integerThe maximum age of a session.

Response

booleanTrue on success, false otherwise.

getInstance

Returns a session storage handler object, only creating it if it doesn't already exist.

getInstance(string $name = 'none', array $options = array()) : \Joomla\Session\Storage
inherited static deprecated
since

1.0

deprecated

2.0

Arguments

$name

stringThe session store to instantiate

$options

arrayArray of options

Response

\Joomla\Session\Storage

isSupported

Test to see if the SessionHandler is available.

isSupported() : boolean
inherited static deprecated
since

1.0

deprecated

2.0

Response

booleanTrue on success, false otherwise.

open

Open the SessionHandler backend.

open(string $save_path, string $session_name) : boolean
inherited deprecated
since

1.0

deprecated

2.0

Arguments

$save_path

stringThe path to the session object.

$session_name

stringThe name of the session.

Response

booleanTrue on success, false otherwise.

read

Read the data for a particular session identifier from the SessionHandler backend.

read(string $id) : string
inherited deprecated
since

1.0

deprecated

2.0

Arguments

$id

stringThe session identifier.

Response

stringThe session data.

register

Register the functions of this class with PHP's session handler

register() : void
inherited deprecated
since

1.0

deprecated

2.0

write

Write session data to the SessionHandler backend.

write(string $id, string $session_data) : boolean
inherited deprecated
since

1.0

deprecated

2.0

Arguments

$id

stringThe session identifier.

$session_data

stringThe session data.

Response

booleanTrue on success, false otherwise.

Properties

db

The DatabaseDriver to use when querying.

deprecated
since

1.0

deprecated

2.0

Type(s)

\Joomla\Database\DatabaseDriver

instances

Storage instances container.

inherited static deprecated
since

1.0

deprecated

2.0

Type(s)

array<mixed,\Joomla\Session\Storage>