php - Route cloud not find driver -


i new whit laravel , write first route , have first problem.

server : php5.6 + mysql + apache2 , linux mint

first install whit :

 composer create-project laravel/laravel test 5.0 --prefer-dist 

and permisions in :

 chmod 777 -r ./storage/ && chmod 777 -r ./bootstrap/ 

in route php

route::get('/test',function (){     echo "batman black color."; }); 

this can go direction localhost/<nameproyect>/test. not go , write check route create fine , write php artisan route:list.

this broblem:

[pdoexception]            not find driver 

in php.ini , have :

extension = pdo.so extension = pdo_mysql.so 

solution :

sudo apt-get install php-mysql 

and other problem :

[2016-11-10 16:15:24] local.error: pdoexception: sqlstate[hy000] [1045] access denied user 'admin'@'localhost' (using password: yes)  

solution whit .env :

db_connection=mysql db_host=127.0.0.1 db_port=3306 db_database=forge db_username=root db_password=1234 

you can install mysql pdo driver installing php5-mysql

sudo apt-get install php5-mysql


Comments

Popular posts from this blog

asynchronous - C# WinSCP .NET assembly: How to upload multiple files asynchronously -

aws api gateway - SerializationException in posting new Records via Dynamodb Proxy Service in API -

asp.net - Problems sending emails from forum -