unkedeuxke
Forum Replies Created
-
Forum: Plugins
In reply to: [WP SlimStat Shortcodes] Display personalized SQL requestAny idea please ?
Forum: Plugins
In reply to: [WP SlimStat Shortcodes] Display personalized SQL requestI just want :
– the visitors currently on the website (so those in the last 10 minutes)
– the visitors who were on the website on the last day (so if somebody visited the website 3 times yesterday it’s 3 visits, and if somebody stayed 30 minutes it’s counted as 3 visits too)Is it clearer ? sorry i’m french ^^
Forum: Plugins
In reply to: [WP SlimStat Shortcodes] Display personalized SQL requestAnother element to be careful of :
If a person is on the website for 18 minutes, I want to count as 2 visits, because 1 visit is considered as 10 minutes timeForum: Plugins
In reply to: [WP SlimStat Shortcodes] Display personalized SQL requestI succeed with that code :
<?php
require_once(WP_PLUGIN_DIR.’/wp-slimstat/admin/view/wp-slimstat-db.php’);
wp_slimstat_db::init();
?>Visiteurs en ligne : <?php echo wp_slimstat_db::count_records(“t1.visit_id > 0 AND t1.dt > UNIX_TIMESTAMP()-600”, ‘t1.id’, false); ?>
But the problem is that at each refresh of the page, the number increases of 1. It’s not a 10 last minutes visitors counter :/
Forum: Plugins
In reply to: [WP SlimStat Shortcodes] Display personalized SQL requestOK, and how can I use it on my widget ?
Just write <?php wp_slimstat_db::count_records(“t1.visit_id > 0 AND t1.dt > UNIX_TIMESTAMP()-300”, ‘t1.id’, false); ?> ?
Because it doesn’t work… Thanks to help me with an example 🙂