gabordemooij/redbean — Issue #130: /tmp directory by default in setup function on Windows environments
Author: mmazzariol-sn
Created: 2012-02-21 11:22:46+00:00
State: open

When creating a new Redbean setup without parameters in a Windows environment I got:

PHP Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[HY000] [14] unable to open database file' in C:\xyz\rb.php:53
Stack trace:
#0 C:\xyz\rb.php(53): PDO->__construct('sqlite:/tmp/red...', NULL, NULL, Array)

Since /tmp is not present in Windows environment is it possible adding a check in Redbean and eventually create the sqlite db in a known directory such as C:\ ?