PHP Fatal error: Uncaught Error: Class 'Mongo' not found - php

I've been trying to install the MongoDB extension for PHP for a while now with no luck. I followed the standard steps:
Installed the driver via Pecl
Added it to my PHP.ini file (both CLI and Apache2)
Restarted Apache2
Yet, my code believes it does not exist:
$conn = new Mongo($_ENV["DB"]);
$db = $conn->test;
PHP Fatal error: Uncaught Error: Class 'Mongo' not found in /var/www/ag/API/index.php:22\nStack trace:\n#0 {main}\n thrown in /var/www/ag/API/index.php on line 22
Any ideas what I am doing wrong? I am using PHP 7.3 and Apache 2.4.38 on Debian
I saw a question like this for Windows, but it was of no help to me.

Related

PHP 7.3.8 Snowflake connection in Mac Os Catalina not working

I'm building the PHP dashboard application with data from snowflake
I'm using the PHP 7.3.8 version.
I'm trying to build the odbc.so file but no success with mac os.
i have try researching but most of the article are base on Linux or Windows machine.
i have try with the pdo drivers but i'm getting the below error message
Fatal error: Uncaught PDOException: could not find driver in....18 Stack trace: #0 /...Stack trace: #0 /
odbc driver error message:
Fatal error: Uncaught Error: Call to undefined function odbc_connect() in ... Stack trace: #0 {main} thrown in
I think both the error mostly because of the missing drivers but i have also try with
with unixodbc
brew install unixodbc but don't know how to connect or configure with php?
please help me on this.
Thanks

Why Mongodb get me error when i call it with MongoClient?

I install mongodb on xampp . It show successfully installed in phpinfo. But when I call it says me this error
Fatal error: Uncaught Error: Class 'MongoClient' not found in ...
my code :
echo extension_loaded('mongodb');
$mongo = new MongoClient("mongodb://localhost:27017");
I install it manually. First line echo true.
MongoClient seems to be part of mongo extension. You are checking for mongodb extension which wouldn't define it.

Fatal error: Call to undefined function mssql_connect() PHP5.5

I am currently migrating a Drupal site for local development. One of the custom modules is throwing an error:
Fatal error: Call to undefined function mssql_connect()
I installed the MS SQL PHP Driver and included it in php.ini
extension=php_sqlsrv_55_ts.dll
extension=php_pdo_sqlsrv_55_ts.dll
However, the error still persists. How can I fix it? the dll's above are for the right version of PHP (5.5.31)

MongoDB - Wampserver : Class 'Mongo' not found

I am trying to install MongoDb on windows platform. I'm using PHP with WampServer.
But while executing the PHP program it gives the following error:
Fatal error: Class 'Mongo' not found in C:\wamp\www\test\index.php on line 19
So is there any way to check whether MongoDB is running with PHP or not ?
Please check php loaded extensions using phpinfo() function whether mongoDB extension is loaded or not.
Do check these as well.
Fatal Error - 'Mongo' class not found
Fatal error: Class 'Mongo' not found in xampp
Add the following line to your php.ini file:
extension=php_mongo.dll
Docs Link: http://php.net/manual/en/mongo.installation.php
Check this possible solution
Copy c:\wamp\bin\php\php-5.3.x\ext\
Edit c:\wamp\bin\apache\Apache2.2.xx\bin\php.ini and add the line where the extensions are loaded.
Why run WAMP on 32bit Windows 7 64bit?
The Mongo PHP driver does not have a 64bit binary win32, if you are running the 64bit version of WAMP, PHP will refuse to load the 32-bit version of php_mongo.dll.

Class 'SoapClient' not found in.. wordpress

I get this error:
Fatal error: Class 'SoapClient' not found in /hoe/roits/wp.com/wp-content/plugins/Aggmges/classitle.php on line 51
Worpress doesnt seem to have the latest php installed as I understand. What can I do to install the newest php or make it so that the SoapClient will work in worpress?
http://php.net/manual/en/soap.installation.php
Install the php soap module if you don't have it, and make sure enabled in php.ini

Categories