I have a SQLite database that I would like to access. I am running on a local WAMP installation.
Apache Version :2.2.17
PHP Version :5.3.5
When I attempt to do this:
It throws an error:
$dbhandle = sqlite_open('db/ledb.sqlite', 0666, $error);
So I checked wether the server installation meets the requirements:
Fatal error: Call to undefined function sqlite_open() in C:\wamp\www\php_test.php on line 3
And it appears to meet the requirements. It is a Windows build and the necessary ini values are enabled. Also full admin privileges.
Any pointers on what is wrong here?
(I worked with SQLite before but not in a php environment so I might be overlooking something important?)
EDIT: The error was caused by not having properly activated the SQLite extension.
However that produces a new issue:
The database can not be accessed
After looking at some topics there seems to be a version problem between the server that created the database and the machine trying to read from it. How do I fix that?
Warning: sqlite_open() [function.sqlite-open]: file is encrypted or is not a database in C:\wamp\www\php_test.php on line 3