Search code examples
phpapilaravel-4contextio

How to add a library that is not for laravel 4.2?


I have this Library from Context.io https://github.com/contextio/contextio-php-example

The Context.io 2.0 has laravel, The Context.io Lite does not.

Im Using The Lite version because its Free.

I would like the Context.io Lite Library installed in my Laravel 4.2.

How to add Context.io Lite Library in my Laravel 4.2 application?

Additional Information:

  • Im developing an API
  • Using PHP laravel 4.2
  • I want to integrate Context.io Lite
  • Context.io Lite Library does not have many files. Just 4 files.php

Solution

  • I'm a developer on the Context.IO team, though only passingly familiar with Laravel. Laravel uses Composer so it should be simple to add the Lite library. Just add this to your composer.json file, which should be in the root of your Laravel project:

    "require": { "contextio/php-contextio-lite": "dev-master" }

    Then run composer install from the command line to install the library.

    The example project can give you some basics to help you get started. Also, don't hesitate to contact the dev team at [email protected] for additional support if you need it.