News:

Wondering if this will always be free?  See why free is better.

Main Menu

Function error

Started by Sir Osis of Liver, April 07, 2023, 10:23:10 PM

Previous topic - Next topic

Sir Osis of Liver

2.0.19, php 7.4. This code in Subs.php -


$result = $smcFunc['db_query']('','
SELECT MAX(last_pic_date)
FROM {db_prefix}gallery_cat');

list($last_pic_date) = $smcFunc['db_fetch_row']($result);
$smcFunc['db_free_result']($result);

if ($last_pic_date > (time() - 86400))
$color = '#FF8300';
else
$color = '';


 is causing this error -


Function name must be a string


Was working for years before uploading clean files.
Even if the whole world has forgotten,
The song remembers when.

                              - H. Prestwood

live627

is the database layer loaded? Is this SSI? Is $smcFunc declared as a global?

Sir Osis of Liver

Yup, forgot to globalize it.  Didn't remember til just before I got up this morning, that's almost 12 hours of brain lag. :(
Even if the whole world has forgotten,
The song remembers when.

                              - H. Prestwood

Advertisement: