?> <option value="<?php echo $cat->id; ?> "<?php echo $category->parent_id == $cat->id ? ' selected' : ''; ?> ><?php echo str_pad("", $level * 2, '|-'), e($cat->name); ?> </option> <?php $displayParents($displayParents, $cat->children, $level + 1); } }; $displayParents($displayParents, Category::getTree()); ?> </select> </div> <div class="col-xs-12 col-md-6 form-group<?php echo $errors->has('image_hash') ? ' has-error' : ''; ?> "> <label>Imagine</label> <input type="file" name="image_hash" class="form-control"> <?php if ($category->image_hash) { ?> <p class="form-control-static"> <img src="<?php echo $category->image->url(['width' => 200]);