sruupl / batflat

Lightweight, fast and easy CMS for free. Bootstrap ready. https://batflat.org
MIT License
135 stars 54 forks source link

Batflat throws an error on XAMPP default installation during freshInstall #69

Closed vxidfunctixn closed 4 years ago

vxidfunctixn commented 4 years ago

In clear XAMPP instalation and eneable debug mode in batflat i receive information:

Fatal error: Uncaught PDOException: could not find driver in C:\xampp\htdocs\project\inc\core\lib\QueryBuilder.php:114 Stack trace:
#0 C:\xampp\htdocs\project\inc\core\lib\QueryBuilder.php(114): PDO->__construct('sqlite:C:\\xampp...', '', '')
#1 C:\xampp\htdocs\project\inc\core\Main.php(354): Inc\Core\Lib\QueryBuilder::connect('sqlite:C:\\xampp...')
#2 C:\xampp\htdocs\project\inc\core\Main.php(93): Inc\Core\Main->freshInstall('C:\\xampp\\htdocs...')
#3 C:\xampp\htdocs\project\inc\core\Site.php(32): Inc\Core\Main->__construct()
#4 C:\xampp\htdocs\project\index.php(28): Inc\Core\Site->__construct()
#5 {main} thrown in C:\xampp\htdocs\project\inc\core\lib\QueryBuilder.php on line 114

The problem occurs on two machines and two clear installations of xampp. If there is need to change a same variable in php.ini? I attach a default php.ini file of xampp. php.txt

michu2k commented 4 years ago

Hi @RiddickAbaddon Batflat should work with the default php.ini config. FYI I also installed a fresh xampp config and everything works fine.

hampelman commented 4 years ago

I get the same kind of error on a fresh install. First a http 500 code. With developers mode to true:

Fatal error: Uncaught PDOException: could not find driver in /htdocs/inc/core/lib/QueryBuilder.php:114 Stack trace: #0 /htdocs/inc/core/lib/QueryBuilder.php(114): PDO->__construct('sqlite:/livedat...', '', '') #1 /htdocs/inc/core/Main.php(354): Inc\Core\Lib\QueryBuilder::connect('sqlite:/livedat...') #2 /htdocs/inc/core/Main.php(93): Inc\Core\Main->freshInstall('/livedata/www/v...') #3 /htdocs/inc/core/Site.php(32): Inc\Core\Main->__construct() #4 /htdocs/index.php(28): Inc\Core\Site->__construct() #5 {main} thrown in /htdocs/inc/core/lib/QueryBuilder.php on line 114

A dive into my PHP configuration (with phpinfo()) gives me the answer: I don't have the PDO SQLite driver installed. This might be the case on your machine ass well @RiddickAbaddon

klocus commented 4 years ago

Yup. You have to install PDO SQLite drivers.