2017 © Pedro Peláez
 

project laraigniter

The CodeIgniter framework

image

recca0120/laraigniter

The CodeIgniter framework

  • Saturday, October 8, 2016
  • by recca0120
  • Repository
  • 4 Watchers
  • 16 Stars
  • 41 Installations
  • HTML
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 1 Open issues
  • 4 Versions
  • 5 % Grown

The README.md

Codeigniter with Eloquent and Blade

Latest Stable Version Total Downloads Latest Unstable Version License Monthly Downloads Daily Downloads, (*1)

Installation

Add Presenter to your composer.json file:, (*2)

"require": {
    "recca0120/laraigniter": "^0.1"
}

Now, run a composer update on the command line from the root of your project:, (*3)

composer update

How to use

import user.sql to mysql, (*4)

Database Config

application/config/database.php, (*5)

$db['default']['hostname'] = 'your hostname';
$db['default']['username'] = 'your username';
$db['default']['password'] = 'your password';
$db['default']['database'] = 'your test';
$db['default']['dbdriver'] = 'mysql';
$db['default']['dbprefix'] = '';
$db['default']['pconnect'] = true;
$db['default']['db_debug'] = true;
$db['default']['cache_on'] = false;
$db['default']['cachedir'] = '';
$db['default']['char_set'] = 'utf8';
$db['default']['dbcollat'] = 'utf8_general_ci';
$db['default']['swap_pre'] = '';
$db['default']['autoinit'] = true;
$db['default']['stricton'] = false;

Model

application/models/User.php, (*6)

namespace App\Models;

use Illuminate\Database\Eloquent\Model;

class User extends Model
{
    protected $fillable = [
        'name',
        'email',
        'password',
    ];
}

Controller

application/controllers/welcome.php, (*7)

if (!defined('BASEPATH')) {
    exit('No direct script access allowed');
}

use App\Models\User;

class Welcome extends CI_Controller
{
    public function index()
    {
        User::create([
            'name'     => 'test'.uniqid(),
            'email'    => 'test'.uniqid().'@test.com',
            'password' => md5('test'.uniqid()),
        ]);

        $users = User::paginate(5);
        $this->output->set_output(View::make('users', compact('users')));
    }
}

View

application/views/users.blade.php, (*8)



@foreach ($users as $user) @endforeach
id name email
{{ $user->id }} {{ $user->name }} {{ $user->email }}
{!! $users->links() !!}

The Versions

08/10 2016

dev-master

9999999-dev https://codeigniter.com

The CodeIgniter framework

  Sources   Download

MIT

The Requires

 

The Development Requires

  • mikey179/vfsstream 1.1.*

12/08 2016

v3.0.0

3.0.0.0 https://codeigniter.com

The CodeIgniter framework

  Sources   Download

MIT

The Requires

 

The Development Requires

  • mikey179/vfsstream 1.1.*

06/08 2016

v2.0.0

2.0.0.0

codeigniter with laravel eloquent, view, pagination

  Sources   Download

MIT

The Requires

 

by Avatar recca0120

laravel eloquent pagination codeigniter blade tracy