Download the PHP package a4anthony/coupon without Composer

On this page you can find all versions of the php package a4anthony/coupon. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

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.
Please rate this library. Is it a good library?

Informations about the package coupon

Coupon Generator for Laravel

Total Downloads Latest Stable Version License

Installation Steps

1. Require the package

After creating your new Laravel application you can include the coupon package with the following command:

2. Add the DB Credentials & APP_URL

Next make sure to create a new database and add your database credentials to your .env file:

You will also want to update your website URL inside of the APP_URL variable inside the .env file:

3. Install coupon generator

Lastly, we can install the coupon generator. You can do this either with or without dummy data. The dummy data will include 1 admin account (if no users already exists) and 5 test coupons

To install the coupon generator without dummy simply run

If you prefer installing it with dummy run

If you encounter any issues with the installation, run the code below to autoload all classes and retry the installation

And we're all good to go!

Start up a local development server with php artisan serve And, visit http://localhost:8000/coupon/dashboard.

Creating an Admin User

If you did go ahead with the dummy data, a user should have been created for you with the following login credentials:

email: [email protected]
password: password

If you did not install the dummy data and you wish to create a new admin user you can pass the --create flag, like so:

And you will be prompted for the user's name and password.

4. Register custom guards for the coupon generator

Go to the the config folder and open the auth.php file. In the providers array, include the code below

In the same file, in the guards array, include the code below

5. Adjust the RedirectIfAuthenticated class to recognize custom guard

Go to app/Http/Middleware/RedirectIfAuthenticated.php and edit the handle() method to the code below:

6. Register the custom middleware class

app/Http/Middleware/RedirectIfAuthenticated.php and include the code below in the $routeMiddleware array

Configuring package

Package can configured in the config/coupon.php file. You can configure timezone, change currency and include currency symbol and also set your error messages.

Usage

Include the package with:

1. Validate coupon and get discount value

2. Callback on successful payment

ENJOY!!!

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

License

MIT


All versions of coupon with dependencies

PHP Build Version
Package Version
Requires illuminate/support Version ~6.0|~7.0
doctrine/dbal Version ^2.5
larapack/doctrine-support Version ~0.1.4
laravel/ui Version >=1.0
ext-json Version *
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 a4anthony/coupon contains the following files

Loading the files please wait ....