Download the PHP package shovv/phalcon-user-plugin without Composer
On this page you can find all versions of the php package shovv/phalcon-user-plugin. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package phalcon-user-plugin
Phalcon User Plugin (v 3.0)
- About
- Features
- Installation
- Plug it
- Configuration
- Example controller
- Known issues
- Examples
- TODO
About
This is a plugin based on Vokuro ACL idea.
Features
- Login / Register with LinkedIn account
- Login / Register with Twitter account
- Login / Register with Google account
- Change password
- Password recovery by email
- Protect different areas from your website, where a user must be logged in, in order to have access
- Protect different actions, based on the ACL list for each user
- User profile: birth date, birth location, current location, profile picture
- Locations - save locations using google API - see Wiki for examples
- Simple notifications system
Installation
The recommended installation is via Composer.
For minor / bug releases (based on semantic versioning):
For all commits and most current version (unstable):
For bug releases only (maximum stability):
Or manually by adding the following to your composer.json
:
and then updating composer:
Plug it
Add the following lines where to your events manager:
Full example code:
Register Auth, Mail and Acl services
Configuration
You must add configuration keys to your config.php file. If you are using a multimodule application, i recommend you to set up the configuration separately for each module.
Configuration examples
In the example bellow, you will treat your website as public, EXCEPT the actions ACCOUNT and PROFILE from the USER controller:
In the example bellow, the ONLY PUBLIC resources are the actions LOGIN and REGISTER from the USER controller:
In the example bellow, you will treat your website as private, EXCEPT the actions LOGIN and REGISTER from the USER controller:
In the example bellow, the ONLY PRIVATE resources are the actions ACCOUNT and PROFILE from the USER controller:
Configuration example with connectors:
Example controller
- For a complete controller example read the Wiki page: https://github.com/calinrada/PhalconUserPlugin/wiki/Controller
Known issues
- Twitter does not provide us the email. We are generating a random email for the user. It is your choice how you handle this
- Facebook lib has no php8 support so it has been removed, login with facebook has been deleted
- Phalcon/incubator has no phalcon5 support, so there will be workarounds
Examples
TODO
- Implement CRUD templates for ACl, UserManagement, etc
- Update Swift Mailer to Symfony Mailer
- Fix failing test for testBeforeDispatchLoopRedirect and testBeforeDispatchLoopFail
- Check @TODOs in code
All versions of phalcon-user-plugin with dependencies
symfony/mailer Version 6.3.0
google/apiclient Version 2.15.*
imagine/imagine Version 1.3.*
paragonie/random_compat Version 2.0.*
facebook/php-sdk-v4 Version 4.0.*