From 8836adc4976bdad0a2f94f7915189f034111b9dd Mon Sep 17 00:00:00 2001 From: Kristina Chodorow Date: Wed, 23 Feb 2011 15:31:00 +0000 Subject: [PATCH] updated constructor params git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@308607 c90b9560-bf6c-de11-be94-00142212c4b1 --- reference/mongo/mongo/construct.xml | 29 +---------------------------- 1 file changed, 1 insertion(+), 28 deletions(-) diff --git a/reference/mongo/mongo/construct.xml b/reference/mongo/mongo/construct.xml index d319d28e4a..847868a711 100644 --- a/reference/mongo/mongo/construct.xml +++ b/reference/mongo/mongo/construct.xml @@ -13,8 +13,6 @@ Mongo::__construct stringserver"mongodb://localhost:27017" arrayoptionsarray("connect" => &true;) - boolpersistfalse - boolgarbagefalse If no parameters are passed, this connects to "localhost:27017" (or whatever @@ -51,31 +49,6 @@ mongodb://[username:password@]host1[:port1][,host2[:port2:],...]/db to authenticate with. If db is not specified, "admin" will be used. - - - If you elect not to connect immediately (you pass the option - array("connect" => false)), you will need to call - Mongo::connect before doing any database operations. - - - - - false)); - -// throws a MongoException, as $mongo has not been fully initialized yet -$mongo->selectDB("foo")->command(array("distinct" => "bar", "key" => "age")); - -// okay -$mongo->connect(); -$mongo->selectDB("foo")->command(array("distinct" => "bar", "key" => "age")); - -?> -]]> - - @@ -259,7 +232,7 @@ $mongo->selectDB("foo")->command(array("distinct" => "bar", "key" => "age")); - 1.1.4 + 1.2.0 Added the username and password options.