Skip to content

Instantly share code, notes, and snippets.

@AlifArnado
Last active November 1, 2015 05:21
Show Gist options
  • Save AlifArnado/4a8e07c82eb2d1ea01a1 to your computer and use it in GitHub Desktop.
Save AlifArnado/4a8e07c82eb2d1ea01a1 to your computer and use it in GitHub Desktop.
test gits
<?php
// create object Class MongoDB
$mongo = new MongoClient();
$db = new Mongo();
$db = $mongo->percobaan;
$collection = $db->profil;
$collection->remove(array('_id' => new MongoId("DB003")), true);
$cursor = $collection->find();
foreach ($cursor as $document) {
echo "<pre>";
//var_dump($document);
echo "<br>";
print_r($document);
echo "<br>";
echo "</pre>";
//echo $document["_id"] ."<br>";
//echo $document["nama"] ."<br>";
//echo $document["nim"] ."<br>";
//echo $document["book"] ."<br>";
//echo $document["by"] ."<br>";
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment