CakePHP Folder Structure

CakePHP file structure

We have used gulp to compile the html, scss and js files.


<?= $this->element("main") ?>

<head>

    <?= $this->element('title-meta', array('title' => 'Dashboard')) ?>

    <?= $this->element("head-css") ?>

</head>

<?= $this->element("body") ?>

    <!-- Begin page -->
    <div id="layout-wrapper">

    <?= $this->element("menu") ?>

        <!-- ============================================================== -->
        <!-- Start right Content here -->
        <!-- ============================================================== -->
        <div class="main-content">

            <div class="page-content">
                <div class="container-fluid">

                <?= $this->element('page-title', array('pagetitle' => 'Skote','title' => 'Dashboard')) ?>

                </div>
                <!-- container-fluid -->
            </div>
            <!-- End Page-content -->

            <?= $this->element("footer") ?>
        </div>
        <!-- end main content-->

    </div>
    <!-- END layout-wrapper -->

    <?= $this->element("right-sidebar") ?>

    <?= $this->element("vendor-scripts") ?>

    <!-- App js -->
    <script src="/js/app.js">

</body>
</html>                                            

Layout setup

You can set the default layout in the templates/element/main.php file in the html tag.

<html data-topbar="light" data-layout-size="boxed"> 
data-sidebar-size="small" To set small layout size.
data-layout-size="boxed" To set boxed layout size.
data-topbar="light" To set the Light color of Topbar.
data-topbar="dark" To set the dark color of Topbar.
data-topbar="colored" To set the colored Topbar.
© Skote.