Skip to content

Commit

Permalink
General fixes
Browse files Browse the repository at this point in the history
+Fixed a bug that didn't show total and online users in the homepage
  • Loading branch information
iopietro committed May 29, 2018
1 parent b629827 commit b052582
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions index.php
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@
<td><?php

$return = mysqli_query($link, "SELECT Count(*) as Total FROM " . TB_PREFIX . "users WHERE tribe IN(1, 2, 3)");
echo !empty($return) ? mysqli_fetch_assoc($return)['Total'] : 0;
echo ($users = !empty($return) ? mysqli_fetch_assoc($return)['Total'] : 0);
?></td>
</tr>

Expand Down Expand Up @@ -159,7 +159,7 @@
<td><?php

$return = mysqli_query($link,"SELECT Count(*) as Total FROM " . TB_PREFIX . "users WHERE timestamp > ".(time() - (60*10))." AND tribe IN(1, 2, 3)");
echo !empty($return) ? mysqli_fetch_assoc($return)['Total'] : 0;
echo ($online = !empty($return) ? mysqli_fetch_assoc($return)['Total'] : 0);

?></td>
</tr>
Expand Down

0 comments on commit b052582

Please sign in to comment.