mirana/tracker

This package is abandoned and no longer maintained. No replacement package was suggested.

A package for your laravel app to track your users.

v1.0.0 2017-03-31 06:47 UTC

This package is not auto-updated.

Last update: 2020-01-24 16:44:39 UTC


README

Index

Installation

Require the tracker package by executing the following command in your command line:

composer require mirana/tracker

Add the service provider to your config/app.php file:

Mirana\Tracker\Laravel\TrackerServiceProvider::class,

Add the alias to the facade on your config/app.php file:

'Tracker' => Mirana\Tracker\Laravel\TrackerFacade::class,

Publish tracker configuration:

php artisan vendor:publish

Add the Middleware to Laravel Kernel

Open the file app/Http/Kernel.php and add the following to your web middlewares:

\Mirana\Tracker\Laravel\TrackerMiddleware::class,

Migrate it

If you have set the default connection to mongodb as it's said in jenssegers/mongodb, you can

php artisan migrate

Update & Changelog

from v0.2.0 to v1.0.0 :

Database
  1. MySql database is not supported anymore & MongoDB will be used instead.*
  2. All migrations changed into a compatible version with MongoDB driver.
  3. session database column uuid changed into session_id.*
Facade
  1. Tracker will be used instead of Mtrack.*
Tracker Session
  1. tracker session now in synced with laravel session through session_id column.

Usage

You can get all the Sessions data as an array by executing the following function in your code:

Tracker::session()

Or in *.blade.php:

{{ Tracker::session() }}

All Tracker functions:

session()
geoip()
device()
referrer()
cookie()
visits()

Resources