PHP Doku:: Create an instance of AMQPConnection - amqpconnection.construct.html

Verlauf / Chronik / History: (1) anzeigen

Sie sind hier:
Doku-StartseitePHP-HandbuchFunktionsreferenzSonstige DiensteAMQPThe AMQPConnection classAMQPConnection::__construct

Ein Service von Reinhard Neidl - Webprogrammierung.

The AMQPConnection class




(PECL amqp >= Unknown)

AMQPConnection::__constructCreate an instance of AMQPConnection


AMQPConnection::__construct ([ array $credentials = array() ] )

Creates an AMQPConnection instance representing a connection to an AMQP broker.



The credentials is an optional array of credential information for connecting to the AMQP broker. The keys used in the credentials array are: host, port, vhost, login and password. All other keys will be ignored.

For each missing credential, the extension will check the ini settings or use the default value.


An AMQPConnection object.


Beispiel #1 AMQPConnection::__construct() example


/* Create a connection using all default credentials: */
$connection1 = new AMQPConnection();

$connection2 = new AMQPConnection(array(
'host' => '',
'vhost' => '/',
'port' => 5763,
'login' => 'user',
'password' => 'password'


Keine BenutzerBeiträge.
- Beiträge aktualisieren...

PHP Powered Diese Seite bei
The PHP manual text and comments are covered by the Creative Commons Attribution 3.0 License © the PHP Documentation Group - Impressum - mail("TO:Reinhard Neidl",...)