Skip to content
Snippets Groups Projects
Commit 45f0a365 authored by Sofiane Lasri's avatar Sofiane Lasri
Browse files

fix

parent b3ca3e83
Branches
No related tags found
No related merge requests found
...@@ -34,12 +34,12 @@ ...@@ -34,12 +34,12 @@
<select multiple class="form-control" name="blocs[]"> <select multiple class="form-control" name="blocs[]">
<?php <?php
$items = Shop::getAllProducts(); $items = Shop::getAllProducts();
foreach($items as $item) {
if(isset($_GET["blocs"]) && in_array($item->getId(), $_GET["blocs"])){ if(isset($_GET["blocs"]) && in_array($item->getId(), $_GET["blocs"])){
$selected = "selected"; $selected = "selected";
}else{ }else{
$selected = ""; $selected = "";
} }
foreach($items as $item) {
echo '<option value="'.$item->getId().'" '.$selected.'><i class="icon-minecraft '.$item->getCss().'"></i> '.$item->getLabel().'</option>'; echo '<option value="'.$item->getId().'" '.$selected.'><i class="icon-minecraft '.$item->getCss().'"></i> '.$item->getLabel().'</option>';
} }
?> ?>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment