2017 © Pedro Peláez
 

library laravel-cornerstone

Some helper functions for Laravel

image

lbausch/laravel-cornerstone

Some helper functions for Laravel

  • Friday, September 1, 2017
  • by lbausch
  • Repository
  • 1 Watchers
  • 1 Stars
  • 1,297 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 23 Versions
  • 1 % Grown

The README.md

Laravel Cornerstone

Build Status, (*1)

Some helper functions for Laravel, (*2)

Documentation

Helper functions

alert

Create a simple alert message., (*3)

function alert($type, $message), (*4)

$type can be one of info, warning, error or success. Requires Twitter Bootstrap to be displayed correctly., (*5)

Example usage: alert('error', 'This didn\'t work');, (*6)

is_active

Checks if current request matches certain controllers and returns the string active if so. Useful for highlighting corresponding navigation items., (*7)

function is_active($needles, $css_classes = ['active']), (*8)

Example usage: is_active('SomeController') or is_active(['SomeController', 'OtherController']). You may also specify the css classes to return with $css_classes., (*9)

Renders a back link. Takes an optional link or tries to use JavaScript., (*10)

function link_back($target = null), (*11)

Example usage: link_back() or link_back(action('SomeController@someMethod')), (*12)

redact

For use in controller methods. Replaces the redirect(action('SomeController@someMethod')) construct., (*13)

function redact($name, $parameters = array(), $status = 302, $headers = array(), $secure = null), (*14)

Added bonus: Use _self to refer to the Controller the function is called in. For example: return redact('_self@index');., (*15)

Repositories

BaseRepositoryInterface

An interface for Repositories. See src/Repositories/BaseRepositoryInterface.php for methods you need to implement., (*16)

EloquentAbstractRepository

Abstract implementation for Eloquent of the above interface. Provides default implementation to extend on. See src/Repositories/EloquentAbstractRepository.php for actual implementation., (*17)

Keep alive

Prevent the CSRF token from timing out. Simple send an AJAX GET request every 5 minutes to the route lbausch/laravel-cornerstone/keepalive. Of course this is only necessary on pages which contain a _token field. To achieve this with jQuery use the following snippet:, (*18)

if ($('input[name=_token]').length > 0) {
    setInterval(function () {
        $.get('lbausch/laravel-cornerstone/keepalive');
    }, 3e5);
}

The Versions

01/09 2017

dev-master

9999999-dev

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

The Development Requires

by Lorenz Bausch

01/09 2017

dev-develop

dev-develop

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

The Development Requires

by Lorenz Bausch

01/09 2017

v5.2.0

5.2.0.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

The Development Requires

by Lorenz Bausch

19/03 2017

v5.1.0

5.1.0.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

The Development Requires

by Lorenz Bausch

29/01 2017

v5.0.0

5.0.0.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

by Lorenz Bausch

07/09 2016

v4.0.0

4.0.0.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

by Lorenz Bausch

28/08 2016

v3.0.2

3.0.2.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

by Lorenz Bausch

25/03 2016

v3.0.1

3.0.1.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

by Lorenz Bausch

18/03 2016

v3.0.0

3.0.0.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

by Lorenz Bausch

16/01 2016

v2.2.1

2.2.1.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

by Lorenz Bausch

03/01 2016

v2.2.0

2.2.0.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

by Lorenz Bausch

02/01 2016

v2.1.0

2.1.0.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

by Lorenz Bausch

30/12 2015

v2.0.0

2.0.0.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

by Lorenz Bausch

04/09 2015

5.1.x-dev

5.1.9999999.9999999-dev

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

by Lorenz Bausch

04/09 2015

v1.3.1

1.3.1.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

by Lorenz Bausch

01/09 2015

v1.3

1.3.0.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

by Lorenz Bausch

30/08 2015

v1.2.4

1.2.4.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

by Lorenz Bausch

03/08 2015

v1.2.3

1.2.3.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

by Lorenz Bausch

27/07 2015

v1.2.2

1.2.2.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

by Lorenz Bausch

22/07 2015

v1.2.1

1.2.1.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

by Lorenz Bausch

12/07 2015

v1.2

1.2.0.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

 

by Lorenz Bausch

10/06 2015

v1.1

1.1.0.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

  • php >=5.4.0

 

by Lorenz Bausch

24/05 2015

v1.0

1.0.0.0

Some helper functions for Laravel

  Sources   Download

MIT

The Requires

  • php >=5.4.0

 

by Lorenz Bausch