Take the 2-minute tour ×

Setting up a new machine, I just discovered the procedural interface to SQLite3 seems to be gone:

PHP Fatal error: Call to undefined function sqlite3_open()

Is there any way to get that back again? I tried Google now for a couple of hours, but found no suitable solution so far. If possible, I don't want to rewrite a bunch of code which worked fine until now (changing it may break it ;) -- so any hints as to how to restore that functionality is highly welcome!

share|improve this question

1 Answer 1

You can easily write a wrapper, then continue using your old functions. Example:


class MyDB extends SQLite3
  function __construct($filename)

if (!is_defined('sqlite3_open')) {
  function sqlite3_open($filename, $mode = 0666, &$error_message)
    $db = new MyDB($filename);
share|improve this answer

Your Answer


