mixed ADOdb_Session::persist( optional mixed $connectMode )
The static method persist sets or gets the status of a persistent connection on the session connection. This is not the same value as the driver associated with the database abstraction layer.
The value must be set before config() is called.
The parameter to the persist()
method sets the connection mode. You can pass the following:
$connectMode | Connection Method |
---|---|
true | pConnect() |
false | connect() |
'N' | nConnect() |
'P' | pConnect() |
'C' | connect() |
When used without parameters it returns the currently set value
include_once 'adodb/adodb.inc.php'; include_once "adodb/session/adodb-session2.php"; ADOdb_Session::driver('oci8'); ADOdb_Session::persist(true); ADOdb_Session::config('',$host,$user,$pass,$database);