• Welcome to the Chevereto User Community!

    Here, users from all over the world come together to learn, share, and collaborate on everything related to Chevereto. It's a place to exchange ideas, ask questions, and help improve the software.

    Please keep in mind:

    • This community is user-driven. Always be polite and respectful to others.
    • Support development by purchasing a Chevereto license, which also gives you priority support.
    • Go further by joining the Community Subscription for even faster response times and to help sustain this space

Quick Stats implementation Home Page/Pages via Dashboard

Status
Not open for further replies.

ashkir

👽 Chevereto Freak
I would love a way to put something like {totalimages} somewhere in the markup for the pages or home page fields in the dashboard without needing to edit PHP or call the database myself.
 
I would love a way to put something like {totalimages} somewhere in the markup for the pages or home page fields in the dashboard without needing to edit PHP or call the database myself.
Bind it in PHP to something simple then use it? PHP will have to be used in some way or another...
 
The system already have this. The CHV\Stat::getTotals() will get you all the global stats.

PHP:
$stats = CHV\Stat::getTotals();
/*
[users] => 1
[images] => 16
[albums] => 2
[image_views] => 17
[likes] => 0
[disk_used] => 18774631
*/
echo $stats['images']; // Will output the total # images
 
Status
Not open for further replies.
Back
Top