Download the PHP
package lightgear/theme without Composer
On this page you can find all versions of the php package
lightgear/theme. It is possible to download/install
these versions without Composer. Possible dependencies are resolved
automatically.
Vendor lightgear Package theme Short Description Easy theme Management for Laravel 4 License
FAQ
After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.
Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.
In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories.
In this case some credentials are needed to access such packages.
Please use the auth.json textarea to insert credentials, if a package is coming from a private repository.
You can look here for more information.
Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
To use Composer is sometimes complicated. Especially for beginners.
Composer needs much resources. Sometimes they are not available on a simple webspace.
If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
The Lightgear Theme package adds support for themes to a Laravel 4 application.
Features
Views overrides for both app and packages
Theme assets (css, less and js) support via Lightgear Asset package
Installation
Via Laravel 4 Package Installer
Manual
Just require
in your composer.json
and run
Then register the service provider
and, optionally, the alias
in app/config/app.php
Important: regardless of the installation method, until I find a better way to handle this, make sure to have the ThemeServiceProvider as the last registered or, at least, after the service providers containing the views you want to override.
This is needed in order to override the packages' views.
Usage
First create the directory that will contain your themes.
By default this is "themes" located in the application root but this can be changed in the config file.
A tipical theme structure would be:
As you notice each theme must have an info.php file with the following contents:
This is a pretty simple structure.
For more information about the theme assets, please refer to Lightgear Asset documentation.
Views overrides
To override any views (be it from app or package) just create the corresponding file in the views directory.
For example, to override the view package::posts.index just create the file views/package/posts/index.php.
The same goes with the views located in the app.
The view posts.index would be overridden in views/posts/index.php.
Configuration
Both the themes directory and the active theme can be set in the config file.
Composer command for our command line client (download client)This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free.Standard composer command
The package lightgear/theme contains the following files
Loading the files please wait ....
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.