<?= $this->extend("layouts/default") ?>

<?= $this->section("title") ?>New Category<?= $this->endSection() ?>

<?= $this->section("content") ?>

    <h1>New Category</h1>
    <?php if(session()->has("errors")): ?>
        <ul>
            <?php foreach(session("errors") as $error): ?>
                <li style="color: red;"><?= $error ?></li>
            <?php endforeach; ?>
        </ul>
    <?php endif; ?>

    <?= form_open("categories") ?>

    <?= $this->include("Categories/form") ?>

    </form>

<?= $this->endSection() ?>

