Jump to content

Recommended Posts

Posted

I am getting a "Fatal error: Class 'PDO' not found" where I was not previously.  I had recently moved some code around, but after restoring it I'm still getting this error.  Is there some trick to pointing to the extension properly.  The line causing the fault is:

 

$dbh = new PDO('sqlite:'.$db_name);

 

The php.ini in my root folder has

 

extension = sqlite3.so
extension = pdo_sqlite.so

 

phpinfo has

 

PDO drivers mysql, pgsql, sqlite

 

 

Posted

First of all, I strongly recommend not using sqlite. You'll get much better performance from mysql or postgresql, and a lot less headaches from trying to debug all the issues that sqlite can have like file permissions. But if you insist on using sqlite we do support it.

 

Second of all, we don't support custom php.ini files. If you need something changed in php.ini you won't be able to change it yourself by placing that file. You'll need to request the changes here on the forums.

 

That said, perhaps this will help? https://stackoverflow.com/a/24588129/2336864

Posted

Thanks, I had inadvertently uploaded a php.ini file from another hosting service, which was apparently being read, so my extensions directory was invalid.  I delete the file, and everything came back online.  

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...