1

I'm making a simple Laravel app for a friend. I got access to their cpanel, made a subdomain, uploaded the app. It seems to be working fine until I try to query the DB from web.php

Route::get('/', function (Product $p) {
    $p = $p -> all();
});

The above line throws an exception saying

Illuminate\Database\QueryException

could not find driver (SQL: select * from products)

The PDO extension is enabled

if (class_exists('PDO')) { 
    echo "installed"; 
} 
else { 
    echo "not installed"; 
}

echoes enabled. Any help would be greatly appreciated.

Community
  • 1
  • 1
  • Possible duplicate of [PDOException “could not find driver”](https://stackoverflow.com/questions/2852748/pdoexception-could-not-find-driver) – aynber Sep 24 '19 at 16:36

0 Answers0