diff --git a/ag/clan/kampf_anzeige.php b/ag/clan/kampf_anzeige.php
index e0cd835..524e410 100644
--- a/ag/clan/kampf_anzeige.php
+++ b/ag/clan/kampf_anzeige.php
@@ -115,14 +115,13 @@ function displayHeader($top, $bottom, $challenge, $clans) {
echo '
';
$max = 0;
$i = 0;
- While($max != $top) {
+ for ($i = 0; $max != $top; $i++) {
if($chars[$i]['clan_id'] == $right) {
echo '';
displayChar($chars[$i]);
echo ' | ';
$max++;
}
- $i++;
}
echo '
| ';
echo '';
@@ -131,36 +130,34 @@ function displayHeader($top, $bottom, $challenge, $clans) {
echo '';
//Darstellen der Bilder auf der linken Seite
echo '';
- $used = $top;
+ $showed = $top;
$max = 0;
$i = 0;
$width = 100 / $bottom;
- While($max != ($bottom+$used)) {
+ for ($i = 0; $max != ($bottom+$showed); $i++) {
if($chars[$i]['clan_id'] == $left) {
- if($max >= $used) {
+ if($max >= $showed) {
echo '';
displayChar($chars[$i]);
echo ' | ';
}
$max++;
}
- $i++;
}
echo '
| ';
//Darstellen der Bilder auf der rechten Seite
echo '';
$max = 0;
$i = 0;
- While($max != ($bottom+$used)) {
+ for ($i = 0; $max != ($bottom+$showed); $i++) {
if($chars[$i]['clan_id'] == $right) {
- if($max >= $used) {
+ if($max >= $showed) {
echo '';
displayChar($chars[$i]);
echo ' | ';
}
$max++;
}
- $i++;
}
echo '
| ';
echo '
';