How to add push notifications to a PHP application with socket.io
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
app
bootstrap
database
public
resources
storage
tests
.env
.env.example
.gitignore
artisan
composer.json
composer.lock
phpunit.xml
readme.md
server.php

readme.md

Tutorial push notifications

demo : https://tutopushnotifications.herokuapp.com/
tutorial (FR) : http://pierrebaron.fr/blog/push-notification-php-nodejs/

This repository provides a base code to a PHP application with push notifications provided by socket.io.

Technologies

  • server : Lumen
  • push : socket.io + elephant.io (socket.io PHP library)
  • client : AngularJS

install

  1. clone the project
  2. run composer install
  3. run mv .env.example .env
  4. Open the .env file and update the APP_KEY and database information
  5. Create a MySQL database
  6. run php artisan migrate to create tables
  7. run cd push; npm install to install nodejs vendor (Express and socket.io)
  8. run npm start to launch the push server
  9. head over to http://localhost:8000 and enjoy !