From d257b144a184f25e6346187e9983e76f4317c465 Mon Sep 17 00:00:00 2001 From: ehpersonal38 <103586016+ehpersonal38@users.noreply.github.com> Date: Wed, 15 Feb 2023 13:46:38 -0500 Subject: [PATCH] Making recordings actually usable for huge amounts of detections --- scripts/play.php | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/scripts/play.php b/scripts/play.php index c211840..e4c020e 100644 --- a/scripts/play.php +++ b/scripts/play.php @@ -398,6 +398,11 @@ if($statement2 == False){ header("refresh: 0;"); } $result2 = $statement2->execute(); +$num_rows = 0; +while ($result2->fetchArray(SQLITE3_ASSOC)) { + $num_rows++; +} +$result2->reset(); // reset the pointer to the beginning of the result set echo " @@ -426,6 +431,12 @@ echo "
$name
} $iter++; + if($num_rows < 100){ + $imageelem = ""; + } else { + $imageelem = ""; + } + if($config["FULL_DISK"] == "purge") { if(!in_array($filename_formatted, $disk_check_exclude_arr)) { $imageicon = "images/unlock.svg"; @@ -455,13 +466,15 @@ echo "
$date $time
$confidence
- + ".$imageelem." + "; } else { echo " + ".$imageelem." + "; }
$date $time
$confidence
-