diff --git a/app/ring_groups/ring_groups.php b/app/ring_groups/ring_groups.php index 09515aa7fe..cce5fad9b9 100644 --- a/app/ring_groups/ring_groups.php +++ b/app/ring_groups/ring_groups.php @@ -67,7 +67,7 @@ echo "\n"; echo " \n"; echo " \n"; -// echo " \n"; + //echo " \n"; echo " \n"; echo " \n"; echo "\n"; - if ($result_count > 0) { - foreach($result as $row) { + if (is_array($ring_groups)) { + foreach($ring_groups as $row) { $tr_link = (permission_exists('ring_group_edit')) ? "href='ring_group_edit.php?id=".$row['ring_group_uuid']."'" : null; echo "\n"; echo " \n"; if ($c==0) { $c=1; } else { $c=0; } } //end foreach - unset($sql, $result, $row_count); + unset($sql, $ring_groups); } //end if results echo "\n"; @@ -207,4 +206,5 @@ //include the footer require_once "resources/footer.php"; + ?>
".$text['title-ring_groups']."  
\n"; echo " \n"; @@ -126,8 +126,7 @@ $sql .= " limit $rows_per_page offset $offset "; $prep_statement = $db->prepare(check_sql($sql)); $prep_statement->execute(); - $result = $prep_statement->fetchAll(); - $result_count = count($result); + $ring_groups = $prep_statement->fetchAll(); unset ($prep_statement, $sql); //set the row styles @@ -153,8 +152,8 @@ echo "
"; @@ -181,7 +180,7 @@ echo "