Braintree payment gateway integration code in laravel

Click here to setup braintree in laravel
<?php

/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
namespace App\Http\Controllers;

use App\Http\Controllers\Controller;
use Auth;
use Illuminate\Support\Facades\Input;
use Braintree_Transaction;
use Braintree_Customer;
use Braintree_WebhookNotification;
use Braintree_Subscription;
use Braintree_CreditCard;
class PaymentController extends Controller { ...  Read More

Share This:


Integrate braintree payment gateway in laravel

1) In your Laravel project's composer.json file, add oureastudios/laravel5-braintree as a dependency in the require object:

"oureastudios/laravel5-braintree": "dev-master"

2) Update the composer

php composer.phar update or composer update

3) Once installed, add the ServiceProvider to your provider array within config/app.php:

'providers' => [
....
/*
* Braintree Service Provider
*/
'Oureastudios\Laravel\BraintreeServiceProvider',
]

4) Configuration

To publish a the package configuration file, run: ...  Read More

Share This:


Simple steps to install Laravel | How to install Laravel | Create first project in Laravel

If you are new to Laravel and wanted to start with Laravel this article is very helpful for you. In this article I'm going to explain how you can install the Laravel on you System. Laravel have some requirements to work so make sure you meets with following requirements.

  • PHP >= 7.0.0
  • OpenSSL PHP Extension
  • PDO PHP Extension
  • Mbstring PHP Extension
  • Tokenizer PHP Extension
  • XML PHP Extension

After meeting these above requirements. Here are the steps to create your first project in Laravel.

1) Install composer

Install curl if you have not installed yet:

a) Global Installation: You can check composer by following command: b) Locally Installation:

2) Install Laravel

If you have installed composer globally: If you have installed composer locally:

* blog is the project name, you can change it according to your project name ...  Read More

Share This:


Routing in laravel

Route::get('/', function(){
return "welcome";
});

Route::post('loginUser', 'UserController@loginUser');
Route::group(['middleware' => ['web']], function () {
Route::get('admin/logout', 'Auth\AuthController@getAdminLogout');
Route::get('admin/login', 'Auth\AuthController@getAdminLogin');
Route::post('auth/login', 'Auth\AuthController@postLogin');
Route::get('auth/logout', 'Auth\AuthController@getLogout');

Route::group(['middleware' => ['auth']], function () {
Route::controller('user', 'UserController');
Route::get('admin/dashboard', 'UserController@dashBoard');
Route::get('admin/profile', 'UserController@getAdminProfile');
Route::post('admin/profile', 'UserController@postAdminProfile'); ...  Read More

Share This: