error: Call to a member function query() on boolean

Hi all,

I just moved a client site (c5.6.3.4) over to a new host.
Before doing this I installed c5 to make sure all needs are met.

Ok, so all went well and I uploaded backup to ftp, imported database, edited config/site.php to reflect new database.

Now when I call the site I get either a blank page or a 500 Internal server error with a timeout message.

In error logs I get this:

[20-Sep-2017 20:04:58 UTC] PHP Fatal error: Call to a member function query() on boolean in /home/mysite/public_html/concrete/core/models/package.php on line 66

lots of time

and then last line this:
[20-Sep-2017 20:06:46 UTC] PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 8546 bytes) in /home/mysite/public_html/concrete/libraries/3rdparty/Zend/Cache/Backend/File.php on line 962

can anyone help me or point me in the right direction of what's going wrong please?

Thxs a lot any help appreciated!

oh almost forgot: this is line 66 of package.php:
$r = $db->query("select pkgID, pkgName, pkgIsInstalled, pkgDescription, pkgVersion, pkgHandle, pkgDateInstalled from Packages where pkgIsInstalled = ? order by pkgID asc", array($pkgIsInstalled));

View Replies:
hutman replied on at Permalink Reply
It looks like the connection to your database might be failing, if $db is false. Did you update your /config/site.php with the update database credentials? Also, did you delete everything in the /files/cache directory?