Hello everyone! Just checking to see if this one is an easy fix with cpg 1.6? The plugin onlinestats that appears on the bottom?
This plugin is essential to my web pages and it gives out (because I used to have an older cpg)
Fatal error: Uncaught Error: Call to undefined function mysql_fetch_row() in /home/minowncu/public_html/addons/kristincavallari.net/gallery/plugins/onlinestats/codebase.php:137 Stack trace: #0 /home/minowncu/public_html/addons/kristincavallari.net/gallery/include/plugin_api.inc.php(218): online_mainpage(Array) #1 /home/minowncu/public_html/addons/kristincavallari.net/gallery/index.php(1128): CPGPluginAPI::filter('plugin_block', Array) #2 {main} thrown in /home/minowncu/public_html/addons/kristincavallari.net/gallery/plugins/onlinestats/codebase.php on line 137
Find plugins updated for CPG 1.6 here: https://github.com/coppermine-gallery/cpg1.6.x-plugins
Hello
How can I change to see the date format as e.g. 6 Jun 2019 ?
Any help please ?
Open codebase.php, find
printf($lang_plugin_onlinestats['record'], '<strong>'.$CONFIG['record_online_users'].'</strong>', localised_date($CONFIG['record_online_date'], $lang_date['lastcom']));
and replace with
printf($lang_plugin_onlinestats['record'], '<strong>'.$CONFIG['record_online_users'].'</strong>', localised_date($CONFIG['record_online_date'], '%e %b %Y'));
I get this error after installig this plugin:
Fatal error: Uncaught TypeError: Unsupported operand types: string + int in /home/-/domains/xxx.net/public_html/cpg/include/functions.inc.php:573 Stack trace: #0 /home/-/domains/xxx.net/public_html/cpg/include/functions.inc.php(543): localised_timestamp() #1 /home/-/domains/xxx.net/public_html/cpg/plugins/onlinestats/codebase.php(192): localised_date() #2 /home/-/domains/xxx.net/public_html/cpg/include/plugin_api.inc.php(215): online_mainpage() #3 /home/-/domains/xxx.net/public_html/cpg/index.php(1125): CPGPluginAPI::filter() #4 {main} thrown in /home/-/domains/xxx.net/public_html/cpg/include/functions.inc.php on line 573
Quote from: panhead on December 04, 2024, 12:29:24 PMI get this error after installig this plugin:
I installed the Onlinestats plugin ( v2.8 ) in the latest release version of CPG ( v1.6.26 ) and experienced no issues.
I installed v2.8 (from github), is there another source?
Quote from: panhead on December 05, 2024, 04:40:05 PMI installed v2.8 (from github), is there another source?
[ Re-entered my previous post to combat smilies ]
No .. that is the most recent (and necessary) version.
I don't know why it should be failing for you .. PHP version maybe? ( my test bed is using 8.3.14 )
if you can modify a file, you might try making this change to
include/functions.inc.php at line(s) 573:
$timestamp = (INT)$timestamp;
$timestamp += ((INT)$CONFIG['time_offset'] - $diff_to_GMT) * 3600;
That seems to work, thank you!
Quote from: panhead on December 06, 2024, 12:21:45 PMThat seems to work, thank you!
That change will not likely be in any new version of CPG. Your gallery may have been around a while. Check your Config->General Settings that the timezone difference seems correctly set. If you are in Nederland it should likely be 0 (zero).