jaysparmar/codeigniter3

A package to work with CodeIgniter 3 framework

1.0.3 2025-08-18 08:50 UTC

This package is auto-updated.

Last update: 2025-08-18 08:54:33 UTC


README

Latest Version on Packagist License: MIT

A package to work with CodeIgniter 3 framework.

Installation

You can install the package via composer:

composer require jaysparmar/codeigniter3

Usage

This package provides a modern way to bootstrap and work with CodeIgniter 3 framework. It includes environment management, path configuration, and CLI support.

Basic Usage

<?php
require_once 'vendor/autoload.php';

use CodeIgniter3\Bootstrap;

// Initialize CodeIgniter 3 environment
Bootstrap::init();

// Your CodeIgniter 3 application code here
// The framework is now properly initialized with:
// - Environment variables loaded from .env file
// - Error reporting configured based on environment
// - System paths properly set up
// - Constants defined

CLI Usage

For command-line applications:

<?php
require_once 'vendor/autoload.php';

use CodeIgniter3\Bootstrap;

// Initialize CodeIgniter 3 for CLI
Bootstrap::initCLI();

// Your CLI application code here

Environment Configuration

Create a .env file in your project root:

ENVIRONMENT=development
# or ENVIRONMENT=production
# or ENVIRONMENT=testing

The package will automatically load environment variables and configure error reporting accordingly.

License

The MIT License (MIT). Please see License File for more information.