From e0ce37c46972f433b5bcafff0abdf5f5a84d9c69 Mon Sep 17 00:00:00 2001 From: pezcurrel Date: Tue, 7 Jun 2022 14:46:08 +0200 Subject: [PATCH] Experiments with times #3 --- web/site/instances.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/web/site/instances.php b/web/site/instances.php index 4eceefd..a8184ef 100644 --- a/web/site/instances.php +++ b/web/site/instances.php @@ -511,7 +511,7 @@ while ($if<$il && $row=mysqli_fetch_assoc($res)) { $out.=''.N; $out.='
'._('Most used hashtags (last week)').' '; - $rres=mysqli_query($link,'SELECT * FROM InstTrends WHERE InstID='.$row['ID'].' ORDER BY Pos ASC') or muorimeglio(__LINE__.': '.mysqli_error($link),true); + $rres=tquery('SELECT * FROM InstTrends WHERE InstID='.$row['ID'].' ORDER BY Pos ASC'); if (mysqli_num_rows($rres)>0) { $buf=array(); while ($rrow=mysqli_fetch_assoc($rres)) @@ -530,7 +530,7 @@ while ($if<$il && $row=mysqli_fetch_assoc($res)) { $out.='
'._('Stats').'
'; - $rres=mysqli_query($link,'SELECT COUNT(InstID) AS cnt, SUM(Statuses) AS tstatuses, SUM(Logins) AS tlogins, SUM(Registrations) AS tregs FROM InstActivity WHERE InstID='.$row['ID']) or muorimeglio(__LINE__.': '.mysqli_error($link),true); + $rres=tquery('SELECT COUNT(InstID) AS cnt, SUM(Statuses) AS tstatuses, SUM(Logins) AS tlogins, SUM(Registrations) AS tregs FROM InstActivity WHERE InstID='.$row['ID']); $out.='
'._('Last 12 weeks activity'); if (mysqli_num_rows($rres)>0) { $rrow=mysqli_fetch_assoc($rres); @@ -538,7 +538,7 @@ while ($if<$il && $row=mysqli_fetch_assoc($res)) { $out.=' ('._('totals:').' '.$rrow['tstatuses'].' '._('statuses').', '.$rrow['tlogins'].' '._('logins').', '.$rrow['tregs'].' '._('registrations').')'; } $out.='
'.N; - $rres=mysqli_query($link,'SELECT * FROM InstActivity WHERE InstID='.$row['ID'].' ORDER BY Week ASC') or muorimeglio(__LINE__.': '.mysqli_error($link),true); + $rres=tquery('SELECT * FROM InstActivity WHERE InstID='.$row['ID'].' ORDER BY Week ASC'); $out.=''; $tot=mysqli_num_rows($rres); if ($tot>0) { @@ -550,7 +550,7 @@ while ($if<$il && $row=mysqli_fetch_assoc($res)) { } $out.='
'.N; - $rres=mysqli_query($link,'SELECT * FROM InstChecks WHERE InstID='.$row['ID'].' ORDER BY Time DESC LIMIT 0,8') or muorimeglio(__LINE__.': '.mysqli_error($link),true); + $rres=tquery($link,'SELECT * FROM InstChecks WHERE InstID='.$row['ID'].' ORDER BY Time DESC LIMIT 0,8'); $tot=mysqli_num_rows($rres); $buf=array(); while ($rrow=mysqli_fetch_assoc($rres)) $buf[]=$rrow;