2017 © Pedro Peláez
 

library laravel-latch

Latch integration in Laravel

image

faytzel/laravel-latch

Latch integration in Laravel

  • Monday, February 23, 2015
  • by faytzel
  • Repository
  • 0 Watchers
  • 4 Stars
  • 706 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 1 Open issues
  • 7 Versions
  • 0 % Grown

The README.md

Laravel (4 and 5) Latch Integration

Installation

Laravel 5

Require this package in your composer.json and run composer update:, (*1)

"faytzel/laravel-latch": "1.*"

After updating composer, add the Service Provider to the providers array in config/app.php, (*2)

'Faytzel\LaravelLatch\LaravelLatchServiceProvider',

You add config files., (*3)

php artisan vendor:publish

If you want to use the facade, add this to your facades in config/app.php, (*4)

'Latch' => 'Faytzel\LaravelLatch\Facades\LaravelLatch',

Laravel 4

Require this package in your composer.json and run composer update:, (*5)

"faytzel/laravel-latch": "0.*"

After updating composer, add the Service Provider to the providers array in app/config/app.php, (*6)

'Faytzel\LaravelLatch\LaravelLatchServiceProvider',

You add config files., (*7)

php artisan config:publish faytzel/laravel-latch

If you want to use the facade, add this to your facades in app/config/app.php, (*8)

'Latch' => 'Faytzel\LaravelLatch\Facades\LaravelLatch',

Examples

Pair with Latch Account

$token = Input::get('token');

if ($accountId = Latch::pair($token))
{
    // Add account id latch to user table
}
else
{
    echo Latch::error();
}

Check it if locked Latch Account

$accountId = 'latch_account_id';

if ( ! Latch::locked($accountId))
{
    // Auth user
}

Check if unlocked Latch Account

$accountId = 'latch_account_id';

if (Latch::unlocked($accountId))
{
    // Auth user
}

Unpair Latch Account

$accountId = 'latch_account_id';

if (Latch::unpair($accountId))
{
    // Delete account id latch in user table
}
else
{
    echo Latch::error();
}

The Versions

23/02 2015

dev-master

9999999-dev

Latch integration in Laravel

  Sources   Download

MIT

The Requires

 

by Avatar faytzel

laravel api php security latch

23/02 2015

1.0.0

1.0.0.0

Latch integration in Laravel

  Sources   Download

MIT

The Requires

 

by Avatar faytzel

laravel api php security latch

01/09 2014

dev-add-latch-sdk-composer

dev-add-latch-sdk-composer

Latch integration in Laravel

  Sources   Download

MIT

The Requires

 

by Avatar faytzel

laravel api php security latch

03/06 2014

dev-develop

dev-develop

Latch integration in Laravel

  Sources   Download

MIT

The Requires

 

by Avatar faytzel

laravel api php security latch

03/06 2014

0.1.2

0.1.2.0

Latch integration in Laravel

  Sources   Download

MIT

The Requires

 

by Avatar faytzel

laravel api php security latch

05/05 2014

0.1.1

0.1.1.0

Latch integration in Laravel

  Sources   Download

MIT

The Requires

 

by Avatar faytzel

laravel api php security latch

05/05 2014

0.1

0.1.0.0

Latch integration in Laravel

  Sources   Download

MIT

The Requires

 

by Avatar faytzel

laravel api php security latch