2017-25 © Pedro Peláez
 

library session

A shrimp of a session library

image

caridea/session

A shrimp of a session library

  • Saturday, January 6, 2018
  • by doublecompile
  • Repository
  • 1 Watchers
  • 0 Stars
  • 618 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 8 Versions
  • 1 % Grown

The README.md

caridea-session

Caridea is a miniscule PHP application library. This shrimpy fellow is what you'd use when you just want some helping hands and not a full-blown framework., (*1)

, (*2)

This is the session component. It's used for controlling sessions (e.g. starting, resuming, destroying) as well as storing namespaced values within a session., (*3)

It supports plugins that get notified of session events. Included in this package are a CSRF prevention plugin and a "flash message" plugin., (*4)

Packagist Build Status Scrutinizer Code Quality Code Coverage, (*5)

Installation

You can install this library using Composer:, (*6)

$ composer require caridea/session
  • The master branch (version 3.x) of this project requires PHP 7.1 and has no dependencies
  • Version 2.x of this project requires PHP 7.0 and has no dependencies
  • Version 1.x of this project requires PHP 5.5 and depends on caridea/random.

Compliance

Releases of this library will conform to Semantic Versioning., (*7)

Our code is intended to comply with PSR-1, PSR-2, and PSR-4. If you find any issues related to standards compliance, please send a pull request!, (*8)

Documentation

Examples

Just a few quick examples., (*9)

Creating a Session., (*10)

// When the session starts, a CSRF token will be created and stored
$csrf = new \Caridea\Session\CsrfPlugin();
// Display-once messages can be added using the flash plugin
$flash = new \Caridea\Session\FlashPlugin();
$session = new \Caridea\Session\NativeSession($_COOKIE, [$csrf, $flash]);

$session->resume() || $session->start();

$flash->set('foo', 'bar');

$token = $csrf->getValue();

$values = $session->getValues('my-namespace');
$values['foobar'] = 'abc123';

The Versions

06/01 2018

dev-master

9999999-dev http://github.com/libreworks/caridea-session

A shrimp of a session library

  Sources   Download

Apache-2.0

The Requires

  • php >=7.1.0

 

The Development Requires

session sessions csrf flash flash message

06/01 2018

3.0.0

3.0.0.0 http://github.com/libreworks/caridea-session

A shrimp of a session library

  Sources   Download

Apache-2.0

The Requires

  • php >=7.1.0

 

The Development Requires

session sessions csrf flash flash message

18/12 2016

2.0.x-dev

2.0.9999999.9999999-dev http://github.com/libreworks/caridea-session

A shrimp of a session library

  Sources   Download

Apache-2.0

The Requires

  • php >=7.0.0

 

The Development Requires

session sessions csrf flash flash message

23/11 2016

2.0.1

2.0.1.0 http://github.com/libreworks/caridea-session

A shrimp of a session library

  Sources   Download

Apache-2.0

The Requires

  • php >=7.0.0

 

The Development Requires

session sessions csrf flash flash message

22/03 2016

2.0.0

2.0.0.0 http://github.com/libreworks/caridea-session

A shrimp of a session library

  Sources   Download

Apache-2.0

The Requires

  • php >=7.0.0

 

The Development Requires

session sessions csrf flash flash message

21/03 2016

1.x-dev

1.9999999.9999999.9999999-dev http://github.com/libreworks/caridea-session

A shrimp of a session library

  Sources   Download

Apache-2.0

The Requires

 

The Development Requires

session sessions csrf flash flash message

21/03 2016

1.0.0

1.0.0.0 http://github.com/libreworks/caridea-session

A shrimp of a session library

  Sources   Download

Apache-2.0

The Requires

 

The Development Requires

session sessions csrf flash flash message

03/06 2015

0.1.0

0.1.0.0 http://github.com/libreworks/caridea-session

A shrimp of a session library

  Sources   Download

Apache-2.0

The Requires

 

session sessions csrf flash flash message