Both SQLite 2 and SQLite 3 on Ubuntu 12.04. PHP plugin
Sqlite 2 is missing from Ubuntu 12.04, since being superceded by Sqlite 3. To install sqlite 2, I got the shared library "sqlite.so" from a previous Ubuntu distribution and installed it here:
Then, I made an ini file in /etc/php5/conf.d/sqlite.ini , with the following content.
; configuration for php SQLite module
To finish just restart apache : service apache2 restart