diff --git a/cont/list.php b/cont/list.php index b12f13c..62d8246 100644 --- a/cont/list.php +++ b/cont/list.php @@ -6,36 +6,38 @@
list as $index => $item) { - if($index%2==0){$color_theme = "bg-primary";} - else{$color_theme = "bg-secondary";} - if($item->Erledigt){ - $div_item_row_color_classes = "bg-success"; - $checked = "checked"; - } - else{ - $div_item_row_color_classes = $color_theme; - $checked = ""; - } - - print_r("
"); - print_r("
"); - print_r("
$item->Anzahl $item->Einheit
"); - print_r("
$item->Name
"); - print_r("
"); - print_r("
"); + foreach ($shopping->list as $index => $item) { + if ($index % 2 == 0) { + $color_theme = "bg-primary"; + } else { + $color_theme = "bg-secondary"; } + if ($item->Erledigt) { + $div_item_row_color_classes = "bg-success"; + $checked = "checked"; + } else { + $div_item_row_color_classes = $color_theme; + $checked = ""; + } + + print_r("
"); + print_r("
"); + print_r("
$item->Anzahl $item->Einheit
"); + print_r("
$item->Name
"); + print_r("
"); + print_r("
"); + } ?>
@@ -43,18 +45,22 @@
- +
- + \ No newline at end of file