Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

SitePoint PHP Blog:
Removing the Pain of User Authorization with Sentinel
Sep 21, 2015 @ 14:23:10

The SitePoint PHP blog has posted a tutorial showing you how to "take the pain out of user authorization" with the help of Sentinel, a package from Cartalyst that already includes functionality for both user authorization and authentication.

Most non-basic multi-user applications need some roles and permission levels. If you ever used WordPress, you must have noticed that they have a super admin, admin, editor, author, etc. Simplifying the development and integration of a permission system is what Cartalyst’s Sentinel package is trying to accomplish. The package provides an API for dealing with users, groups, permissions, etc. In this article, we’ll use it to create a small demo app.

They walk through the creation of a simple Slim framework application, installing it, Sentinel and other suggested packages via Composer. They then help you execute the migrations to create the necessary tables and set up a basic front controller file. From there they configure Twig templating, the Illuminate database connection and finally adding a Sentinel instance to the application's DI container. They include code to help you create roles for "user" and "admin". From there the tutorial shows how to create a login & registration form, send a registration email, create permissions and activating users. Finally they build a simple administration page that allows you to hide functionality from normal users.

tagged: tutorial authentication authorization sentinel cartalyst slim illuminate

Link: http://www.sitepoint.com/removing-the-pain-of-user-authorization-with-sentinel/

PHP Town Hall:
Episode 27: Josh Lockhart and Jeremy Mikola
Jun 30, 2014 @ 09:30:35

The PHP Town Hall podcast is back with their latest episode, number 27, featuring two special guests: Jeremy Mikola and Josh Lockhart.

This episode is a long one, but we are back to improved audio and the video is not just one dude eating pizza for an hour. Josh Lockhart of PHP The Right Way and Slim fame, and Jeremy Mikola who is well known for banging on about clouds and playing magic the gathering. Oh, he also works for MongoDB.

The episode's discussion includes a wide range of topics (and plenty of rambling) about things like plans for Slim 3, Silex vs Slim, PHP The Right Way, Illuminate/Pagination and difficulties around pull requests. You can listen to this latest episode either through the in-page player, by downloading the mp3 or you can watch the video of the live Google Hangout recording.

tagged: phptownhall ep27 jeremymikola joshlockhart slim phptherightway illuminate pullrequest

Link: http://phptownhall.com//blog/2014/06/29/episode-27-foo/