Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/aididalam/codeigniter-eloquent-orm

Eloquent ORM intrigatted in Codeigniter 3
https://github.com/aididalam/codeigniter-eloquent-orm

codeigniter codeigniter-eloquent codeigniter-library codeigniter-model codeigniter-orm eloquent eloquent-orm

Last synced: about 1 month ago
JSON representation

Eloquent ORM intrigatted in Codeigniter 3

Awesome Lists containing this project

README

        

## Codeigniter 3.1.0 Integrated with Illuminate Database Eloquent

### Requires

php: >=5.3.7

### Installation

Install the Illuminate Database package with Composer:

```sh
$ composer install
```

### Using The Eloquent ORM

**Example:**

Model

```php
load->model('user');
$users = User::where('votes', '>', 1)->get();
$this->load->view('home/index', ['users' => $users]);
}
}
```
### Bonus
dd() Function is also implemented;
Example:
```php
class Home extends CI_Controller {

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

### Documentation

- [CodeIgniter documentation](http://www.codeigniter.com/user_guide/)

- [Laravel framework - Eloquent documentation](https://laravel.com/docs/9.x/eloquent)

### Inspired From

- [codeigniter-eloquent](https://github.com/aduartem/codeigniter-eloquent/)