Codeigniter Folder Structure

PHP Folder Structure

Ajax Folder Structure

Codeigniter file structure

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


<?= $this->element('partials/main') ?>

<head>

    <?= $title_meta ?>

    <?= $this->element('partials/head-css') ?>

</head>

<?= $this->element('partials/body') ?>

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

    <?= $this->element('partials/menu') ?>

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

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

                    <?= $page_title ?>

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

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

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

    <?= $this->element('partials/right-sidebar') ?>

    <?= $this->element('partials/vendor-scripts') ?>

    <!-- App js -->
    <script src="assets/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-bs-theme="light" To set Light layout mode.
data-bs-theme="dark" To set Dark layout mode.
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.