PHP Classes

Codeigniter Eloquent ORM: Store CodeIgniter model objects using Eloquent ORM

Recommend this page to a friend!
  Info   View files Documentation   View files View files (256)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Last Updated Ratings Unique User Downloads Download Rankings
2022-05-11 (24 days ago) RSS 2.0 feedNot yet rated by the usersTotal: Not yet counted Not yet ranked
Version License PHP version Categories
codeigniter-eloquent 1.0The PHP License5PHP 5, Libraries, Design Patterns
Description Author

This package can store and retrieve CodeIgniter model objects using Eloquent ORM.

It provides an example application that demonstrates how to use the Eloquent object-relational mapping package to store and retrieve in database tables the model class objects created using the CodeIgnieter framework.

PHP application developers can learn how to create CodeIgniter controller applications that call model classes that extend the Eloquent base model classes.

Innovation Award
PHP Programming Innovation award nominee
May 2022
Nominee
Vote
CodeIgniter is a popular PHP framework used by many developers to implement PHP applications following a consistent development method.

Eloquent ORM is a PHP package that can map model classes to database table records to store application data objects.

Often the Eloquent ORM is used in PHP applications that use the Laravel framework.

This package demonstrates that PHP developers can use to learn how to use the Eloquent ORM model class objects in a CodeIgniter application.

Manuel Lemos
Picture of aidid alam
Name: aidid alam <contact>
Classes: 2 packages by
Country: Bangladesh Bangladesh
Innovation award
Innovation award
Nominee: 2x

Details

Codeigniter 3.1.0 Integrated with Illuminate Database Eloquent

Requires

php: >=5.3.7

Installation

Install the Illuminate Database package with Composer:

$ composer install

Using The Eloquent ORM

Example:

Model

<?php
use \Illuminate\Database\Eloquent\Model as Eloquent;

class User extends Eloquent{
    protected $table = 'users';

}

Controller

defined('BASEPATH') OR exit('No direct script access allowed');

class Home extends CI_Controller {

	public function index()
	{
		$this->load->model('user');
		$users = User::where('votes', '>', 1)->get();
		$this->load->view('home/index', ['users' => $users]);
	}
}

Bonus

dd() Function is also implemented; Example:

class Home extends CI_Controller {

	public function index()
	{
		$this->load->model('user');
		$users = User::all();
        dd($users);
	}
}

Documentation

Inspired From

  Files folder image Files  
File Role Description
Files folder imageapplication (2 files, 12 directories)
Files folder imagesystem (2 files, 7 directories)
Accessible without login Plain text file .editorconfig Data Auxiliary data
Accessible without login Plain text file composer.json Data Auxiliary data
Accessible without login Plain text file index.php Aux. Auxiliary script
Accessible without login Plain text file readme.md Doc. Read me

  Files folder image Files  /  application  
File Role Description
Files folder imagecache (1 file)
Files folder imageconfig (15 files)
Files folder imagecontrollers (2 files)
Files folder imagecore (1 file)
Files folder imagehelpers (1 file)
Files folder imagehooks (1 file)
Files folder imagelanguage (1 file, 1 directory)
Files folder imagelibraries (1 file)
Files folder imagelogs (1 file)
Files folder imagemodels (2 files)
Files folder imagethird_party (1 file)
Files folder imageviews (1 file, 1 directory)
  Accessible without login Plain text file .htaccess Data Auxiliary data
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  application  /  cache  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  application  /  config  
File Role Description
  Accessible without login Plain text file autoload.php Aux. Auxiliary script
  Accessible without login Plain text file config.php Aux. Auxiliary script
  Accessible without login Plain text file constants.php Aux. Auxiliary script
  Accessible without login Plain text file database.php Example Example script
  Accessible without login Plain text file doctypes.php Aux. Auxiliary script
  Accessible without login Plain text file foreign_chars.php Aux. Auxiliary script
  Accessible without login Plain text file hooks.php Aux. Auxiliary script
  Accessible without login HTML file index.html Doc. Documentation
  Accessible without login Plain text file memcached.php Aux. Auxiliary script
  Accessible without login Plain text file migration.php Aux. Auxiliary script
  Accessible without login Plain text file mimes.php Aux. Auxiliary script
  Accessible without login Plain text file profiler.php Aux. Auxiliary script
  Accessible without login Plain text file routes.php Aux. Auxiliary script
  Accessible without login Plain text file smileys.php Aux. Auxiliary script
  Accessible without login Plain text file user_agents.php Aux. Auxiliary script

  Files folder image Files  /  application  /  controllers  
File Role Description
  Plain text file Home.php Class Class source
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  application  /  core  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  application  /  helpers  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  application  /  hooks  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  application  /  language  
File Role Description
Files folder imageenglish (1 file)
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  application  /  language  /  english  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  application  /  libraries  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  application  /  logs  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  application  /  models  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation
  Plain text file User.php Class Class source

  Files folder image Files  /  application  /  third_party  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  application  /  views  
File Role Description
Files folder imageerrors (1 file, 2 directories)
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  application  /  views  /  errors  
File Role Description
Files folder imagecli (6 files)
Files folder imagehtml (6 files)
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  application  /  views  /  errors  /  cli  
File Role Description
  Accessible without login Plain text file error_404.php Aux. Auxiliary script
  Accessible without login Plain text file error_db.php Aux. Auxiliary script
  Accessible without login Plain text file error_exception.php Example Example script
  Accessible without login Plain text file error_general.php Aux. Auxiliary script
  Accessible without login Plain text file error_php.php Aux. Auxiliary script
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  application  /  views  /  errors  /  html  
File Role Description
  Accessible without login Plain text file error_404.php Aux. Auxiliary script
  Accessible without login Plain text file error_db.php Aux. Auxiliary script
  Accessible without login Plain text file error_exception.php Example Example script
  Accessible without login Plain text file error_general.php Aux. Auxiliary script
  Accessible without login Plain text file error_php.php Aux. Auxiliary script
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  system  
File Role Description
Files folder imagecore (18 files, 1 directory)
Files folder imagedatabase (8 files, 1 directory)
Files folder imagefonts (1 file)
Files folder imagehelpers (22 files)
Files folder imagelanguage (1 file, 1 directory)
Files folder imagelibraries (24 files, 3 directories)
Files folder imagesessions (3 files)
  Accessible without login Plain text file .htaccess Data Auxiliary data
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  system  /  core  
File Role Description
Files folder imagecompat (5 files)
  Plain text file Benchmark.php Class Class source
  Accessible without login Plain text file CodeIgniter.php Example Example script
  Accessible without login Plain text file Common.php Example Example script
  Plain text file Config.php Class Class source
  Plain text file Controller.php Class Class source
  Plain text file Exceptions.php Class Class source
  Plain text file Hooks.php Class Class source
  Accessible without login HTML file index.html Doc. Documentation
  Plain text file Input.php Class Class source
  Plain text file Lang.php Class Class source
  Plain text file Loader.php Class Class source
  Plain text file Log.php Class Class source
  Plain text file Model.php Class Class source
  Plain text file Output.php Class Class source
  Plain text file Router.php Class Class source
  Plain text file Security.php Class Class source
  Plain text file URI.php Class Class source
  Plain text file Utf8.php Class Class source

  Files folder image Files  /  system  /  core  /  compat  
File Role Description
  Accessible without login Plain text file hash.php Aux. Auxiliary script
  Accessible without login HTML file index.html Doc. Documentation
  Accessible without login Plain text file mbstring.php Aux. Auxiliary script
  Accessible without login Plain text file password.php Example Example script
  Accessible without login Plain text file standard.php Aux. Auxiliary script

  Files folder image Files  /  system  /  database  
File Role Description
Files folder imagedrivers (1 file, 12 directories)
  Plain text file DB.php Class Class source
  Plain text file DB_cache.php Class Class source
  Plain text file DB_driver.php Class Class source
  Plain text file DB_forge.php Class Class source
  Plain text file DB_query_builder.php Class Class source
  Plain text file DB_result.php Class Class source
  Plain text file DB_utility.php Class Class source
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  system  /  database  /  drivers  
File Role Description
Files folder imagecubrid (5 files)
Files folder imageibase (5 files)
Files folder imagemssql (5 files)
Files folder imagemysql (5 files)
Files folder imagemysqli (5 files)
Files folder imageoci8 (5 files)
Files folder imageodbc (5 files)
Files folder imagepdo (5 files, 1 directory)
Files folder imagepostgre (5 files)
Files folder imagesqlite (5 files)
Files folder imagesqlite3 (5 files)
Files folder imagesqlsrv (5 files)
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  system  /  database  /  drivers  /  cubrid  
File Role Description
  Plain text file cubrid_driver.php Class Class source
  Plain text file cubrid_forge.php Class Class source
  Plain text file cubrid_result.php Class Class source
  Plain text file cubrid_utility.php Class Class source
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  system  /  database  /  drivers  /  ibase  
File Role Description
  Plain text file ibase_driver.php Class Class source
  Plain text file ibase_forge.php Class Class source
  Plain text file ibase_result.php Class Class source
  Plain text file ibase_utility.php Class Class source
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  system  /  database  /  drivers  /  mssql  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation
  Plain text file mssql_driver.php Class Class source
  Plain text file mssql_forge.php Class Class source
  Plain text file mssql_result.php Class Class source
  Plain text file mssql_utility.php Class Class source

  Files folder image Files  /  system  /  database  /  drivers  /  mysql  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation
  Plain text file mysql_driver.php Class Class source
  Plain text file mysql_forge.php Class Class source
  Plain text file mysql_result.php Class Class source
  Plain text file mysql_utility.php Class Class source

  Files folder image Files  /  system  /  database  /  drivers  /  mysqli  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation
  Plain text file mysqli_driver.php Class Class source
  Plain text file mysqli_forge.php Class Class source
  Plain text file mysqli_result.php Class Class source
  Plain text file mysqli_utility.php Class Class source

  Files folder image Files  /  system  /  database  /  drivers  /  oci8  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation
  Plain text file oci8_driver.php Class Class source
  Plain text file oci8_forge.php Class Class source
  Plain text file oci8_result.php Class Class source
  Plain text file oci8_utility.php Class Class source

  Files folder image Files  /  system  /  database  /  drivers  /  odbc  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation
  Plain text file odbc_driver.php Class Class source
  Plain text file odbc_forge.php Class Class source
  Plain text file odbc_result.php Class Class source
  Plain text file odbc_utility.php Class Class source

  Files folder image Files  /  system  /  database  /  drivers  /  pdo  
File Role Description
Files folder imagesubdrivers (25 files)
  Accessible without login HTML file index.html Doc. Documentation
  Plain text file pdo_driver.php Class Class source
  Plain text file pdo_forge.php Class Class source
  Plain text file pdo_result.php Class Class source
  Plain text file pdo_utility.php Class Class source

  Files folder image Files  /  system  /  database  /  drivers  /  pdo  /  subdrivers  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation
  Plain text file pdo_4d_driver.php Class Class source
  Plain text file pdo_4d_forge.php Class Class source
  Plain text file pdo_cubrid_driver.php Class Class source
  Plain text file pdo_cubrid_forge.php Class Class source
  Plain text file pdo_dblib_driver.php Class Class source
  Plain text file pdo_dblib_forge.php Class Class source
  Plain text file pdo_firebird_driver.php Class Class source
  Plain text file pdo_firebird_forge.php Class Class source
  Plain text file pdo_ibm_driver.php Class Class source
  Plain text file pdo_ibm_forge.php Class Class source
  Plain text file pdo_informix_driver.php Class Class source
  Plain text file pdo_informix_forge.php Class Class source
  Plain text file pdo_mysql_driver.php Class Class source
  Plain text file pdo_mysql_forge.php Class Class source
  Plain text file pdo_oci_driver.php Class Class source
  Plain text file pdo_oci_forge.php Class Class source
  Plain text file pdo_odbc_driver.php Class Class source
  Plain text file pdo_odbc_forge.php Class Class source
  Plain text file pdo_pgsql_driver.php Class Class source
  Plain text file pdo_pgsql_forge.php Class Class source
  Plain text file pdo_sqlite_driver.php Class Class source
  Plain text file pdo_sqlite_forge.php Class Class source
  Plain text file pdo_sqlsrv_driver.php Class Class source
  Plain text file pdo_sqlsrv_forge.php Class Class source

  Files folder image Files  /  system  /  database  /  drivers  /  postgre  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation
  Plain text file postgre_driver.php Class Class source
  Plain text file postgre_forge.php Class Class source
  Plain text file postgre_result.php Class Class source
  Plain text file postgre_utility.php Class Class source

  Files folder image Files  /  system  /  database  /  drivers  /  sqlite  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation
  Plain text file sqlite_driver.php Class Class source
  Plain text file sqlite_forge.php Class Class source
  Plain text file sqlite_result.php Class Class source
  Plain text file sqlite_utility.php Class Class source

  Files folder image Files  /  system  /  database  /  drivers  /  sqlite3  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation
  Plain text file sqlite3_driver.php Class Class source
  Plain text file sqlite3_forge.php Class Class source
  Plain text file sqlite3_result.php Class Class source
  Plain text file sqlite3_utility.php Class Class source

  Files folder image Files  /  system  /  database  /  drivers  /  sqlsrv  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation
  Plain text file sqlsrv_driver.php Class Class source
  Plain text file sqlsrv_forge.php Class Class source
  Plain text file sqlsrv_result.php Class Class source
  Plain text file sqlsrv_utility.php Class Class source

  Files folder image Files  /  system  /  fonts  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  system  /  helpers  
File Role Description
  Accessible without login Plain text file array_helper.php Aux. Auxiliary script
  Accessible without login Plain text file captcha_helper.php Example Example script
  Accessible without login Plain text file cookie_helper.php Example Example script
  Accessible without login Plain text file date_helper.php Example Example script
  Accessible without login Plain text file directory_helper.php Aux. Auxiliary script
  Accessible without login Plain text file download_helper.php Aux. Auxiliary script
  Accessible without login Plain text file email_helper.php Aux. Auxiliary script
  Accessible without login Plain text file file_helper.php Aux. Auxiliary script
  Accessible without login Plain text file form_helper.php Example Example script
  Accessible without login Plain text file html_helper.php Example Example script
  Accessible without login HTML file index.html Doc. Documentation
  Accessible without login Plain text file inflector_helper.php Aux. Auxiliary script
  Accessible without login Plain text file language_helper.php Example Example script
  Accessible without login Plain text file number_helper.php Example Example script
  Accessible without login Plain text file path_helper.php Aux. Auxiliary script
  Accessible without login Plain text file security_helper.php Example Example script
  Accessible without login Plain text file smiley_helper.php Aux. Auxiliary script
  Accessible without login Plain text file string_helper.php Aux. Auxiliary script
  Accessible without login Plain text file text_helper.php Aux. Auxiliary script
  Accessible without login Plain text file typography_helper.php Example Example script
  Accessible without login Plain text file url_helper.php Example Example script
  Accessible without login Plain text file xml_helper.php Aux. Auxiliary script

  Files folder image Files  /  system  /  language  
File Role Description
Files folder imageenglish (14 files)
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  system  /  language  /  english  
File Role Description
  Accessible without login Plain text file calendar_lang.php Aux. Auxiliary script
  Accessible without login Plain text file date_lang.php Aux. Auxiliary script
  Accessible without login Plain text file db_lang.php Aux. Auxiliary script
  Accessible without login Plain text file email_lang.php Aux. Auxiliary script
  Accessible without login Plain text file form_validation_lang.php Aux. Auxiliary script
  Accessible without login Plain text file ftp_lang.php Aux. Auxiliary script
  Accessible without login Plain text file imglib_lang.php Aux. Auxiliary script
  Accessible without login HTML file index.html Doc. Documentation
  Accessible without login Plain text file migration_lang.php Aux. Auxiliary script
  Accessible without login Plain text file number_lang.php Aux. Auxiliary script
  Accessible without login Plain text file pagination_lang.php Aux. Auxiliary script
  Accessible without login Plain text file profiler_lang.php Aux. Auxiliary script
  Accessible without login Plain text file unit_test_lang.php Aux. Auxiliary script
  Accessible without login Plain text file upload_lang.php Aux. Auxiliary script

  Files folder image Files  /  system  /  libraries  
File Role Description
Files folder imageCache (2 files, 1 directory)
Files folder imageJavascript (2 files)
Files folder imageSession (8 files, 1 directory)
  Plain text file Calendar.php Class Class source
  Plain text file Cart.php Class Class source
  Plain text file Driver.php Class Class source
  Plain text file Email.php Class Class source
  Plain text file Encrypt.php Class Class source
  Plain text file Encryption.php Class Class source
  Plain text file Form_validation.php Class Class source
  Plain text file Ftp.php Class Class source
  Plain text file Image_lib.php Class Class source
  Accessible without login HTML file index.html Doc. Documentation
  Plain text file Javascript.php Class Class source
  Plain text file Migration.php Class Class source
  Plain text file Pagination.php Class Class source
  Plain text file Parser.php Class Class source
  Plain text file Profiler.php Class Class source
  Plain text file Table.php Class Class source
  Plain text file Trackback.php Class Class source
  Plain text file Typography.php Class Class source
  Plain text file Unit_test.php Class Class source
  Plain text file Upload.php Class Class source
  Plain text file User_agent.php Class Class source
  Plain text file Xmlrpc.php Class Class source
  Plain text file Xmlrpcs.php Class Class source
  Plain text file Zip.php Class Class source

  Files folder image Files  /  system  /  libraries  /  Cache  
File Role Description
Files folder imagedrivers (7 files)
  Plain text file Cache.php Class Class source
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  system  /  libraries  /  Cache  /  drivers  
File Role Description
  Plain text file Cache_apc.php Class Class source
  Plain text file Cache_dummy.php Class Class source
  Plain text file Cache_file.php Class Class source
  Plain text file Cache_memcached.php Class Class source
  Plain text file Cache_redis.php Class Class source
  Plain text file Cache_wincache.php Class Class source
  Accessible without login HTML file index.html Doc. Documentation

  Files folder image Files  /  system  /  libraries  /  Javascript  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation
  Plain text file Jquery.php Class Class source

  Files folder image Files  /  system  /  libraries  /  Session  
File Role Description
Files folder imagedrivers (5 files)
  Plain text file CI_Session_driver_interface.php Class Class source
  Accessible without login HTML file index.html Doc. Documentation
  Plain text file OldSessionWrapper.php Class Class source
  Plain text file PHP8SessionWrapper.php Class Class source
  Plain text file Session.php Class Class source
  Plain text file SessionHandlerInterface.php Class Class source
  Plain text file SessionUpdateTimes...andlerInterface.php Class Class source
  Plain text file Session_driver.php Class Class source

  Files folder image Files  /  system  /  libraries  /  Session  /  drivers  
File Role Description
  Accessible without login HTML file index.html Doc. Documentation
  Plain text file Session_database_driver.php Class Class source
  Plain text file Session_files_driver.php Class Class source
  Plain text file Session_memcached_driver.php Class Class source
  Plain text file Session_redis_driver.php Class Class source

  Files folder image Files  /  system  /  sessions  
File Role Description
  Accessible without login Plain text file ci_session30lds4v2...5eo5hpa03quihq62bj1 Data Auxiliary data
  Accessible without login Plain text file ci_sessiongbchjcmn...cil6j5gvan0jbf485dd Data Auxiliary data
  Accessible without login Plain text file ci_sessionlotns5t2...qk2prf6hj1d4doeecpt Data Auxiliary data

 Version Control Unique User Downloads  
 100%
Total:0
This week:0
For more information send a message to info at phpclasses dot org.