From 0ff6415f9d22592d03f8394f37db2b0f4ffb7006 Mon Sep 17 00:00:00 2001 From: Kristina Chodorow Date: Fri, 29 May 2009 20:03:49 +0000 Subject: [PATCH] DB::command and date fields git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@281414 c90b9560-bf6c-de11-be94-00142212c4b1 --- reference/mongo/examples.xml | 7 ++--- reference/mongo/mongodate.xml | 5 ++- .../dbcommand.xml => mongodb/command.xml} | 31 +++---------------- 3 files changed, 11 insertions(+), 32 deletions(-) rename reference/mongo/{mongoutil/dbcommand.xml => mongodb/command.xml} (56%) diff --git a/reference/mongo/examples.xml b/reference/mongo/examples.xml index 90ec090396..f6530cd6b3 100644 --- a/reference/mongo/examples.xml +++ b/reference/mongo/examples.xml @@ -1,5 +1,5 @@ - + &reftitle.examples; @@ -35,9 +35,8 @@ $collection->insert($obj); $cursor = $collection->find(); // iterate through the results -while( $cursor->hasNext() ) { - $c = $cursor->next(); - echo $c["title"] . "\n"; +foreach ($cursor as $obj) { + echo $obj["title"] . "\n"; } // disconnect diff --git a/reference/mongo/mongodate.xml b/reference/mongo/mongodate.xml index 60de361a51..1c98ff3c92 100644 --- a/reference/mongo/mongodate.xml +++ b/reference/mongo/mongodate.xml @@ -1,5 +1,5 @@ - + @@ -14,6 +14,9 @@ Represent date objects for the database. + + Includes second (sec) and microsecond (usec) fields. + diff --git a/reference/mongo/mongoutil/dbcommand.xml b/reference/mongo/mongodb/command.xml similarity index 56% rename from reference/mongo/mongoutil/dbcommand.xml rename to reference/mongo/mongodb/command.xml index df6a150d2e..5d3d2e8797 100644 --- a/reference/mongo/mongoutil/dbcommand.xml +++ b/reference/mongo/mongodb/command.xml @@ -1,35 +1,22 @@ - + - MongoUtil::dbCommand - Execute a db command + MongoDB::command + Execute a database command &reftitle.description; - public static arrayMongoUtil::dbCommand - resourceconn + public arrayMongoDB::command arraydata - stringdb &reftitle.parameters; - - - resource - conn - - - - Database connection. - - - data @@ -40,16 +27,6 @@ - - - db - - - - The database name. - - -