I am working on my local wamp server and trying to retrieve data from a phpMyAdmin. But i am getting an error.
could not find driver 500 Internal Server Error - PDOException
my routing.yml
# This file is auto-generated during the composer install
parameters:
database_driver: pdo_mysql
database_host: www.example.com
database_port: null
database_name: mydb
database_user: myuser
database_password: mypass
mailer_transport: smtp
mailer_host: www.example.com
mailer_user: null
mailer_password: null
locale: en
secret: ThisTokenIsNotSoSecretChangeIt
database_path: null
my controller
$connection = $this->get("database_connection");
$statement = $connection->prepare("SELECT * FROM table");
$statement->execute();
$tabs = $statement->fetchAll();