title: Fatal error: Class 'Mongo' not found in C:\\Apache Software Foundation\Apache2.2\htdocs\sample\testdb.php
body: <p>Fatal error:</p>
  
  <blockquote>
    <p>Class 'Mongo' not found in C:\Apache
    Software
    Foundation\Apache2.2\htdocs\sample\testdb.php</p>
  </blockquote>
  
  <p>Can anyone help me out with this issue? Why is that saying so? </p>
  
  <p>The following is the code that I have used. I have created a database named <code>phptest</code> in MongoDB and inserted a document. Then I tried connecting to MongoDB via PHP but it threw this error. </p>
  
  <p>Can anyone help me get rid of this? I have included the php-mongo dll and saved in php.ini file also.</p>
  
  <pre><code>&lt;?php
  echo "succeeded!";
  $connection = new Mongo();
  $db = $connection-&gt;test;
  $collection = $db-&gt;phptest;
  ?&gt;
  </code></pre>