In Laravel 5 REST API project sometime we need to create create our own custom header for security. like : 'X-hardik':'123456'. this was example, that means in your current project your every request with pass your own custom header like i give you example.this custom ...
iam new and just learning about laravel SPA . i try to create project laravel spa from github : https://github.com/cretueusebiu/laravel-vue-spa . so next step i want to add middleware , but in the structure i dont know what happens to do . this folde
Run Migrations: Laravel provides a migration system to manage your database structure. You can create migration files using the make:migration command and execute them using the migrate command. Open a terminal and navigate to the root directory of your Laravel project. Run the following command t...
In this tutorial, i would like to share with you how to build restful api in laravel 5.5 application. Here i will share with you create basic and simple resource api route with json response. you can simply use with your big project, you can make basic setup for you application. Before ...
Middleware in Controllers Middleware in Laravel provides a way to filter HTTP requests before they reach your controllers. You can assign middleware to a controller method or the entire controller: classMyControllerextendsController{publicfunction__construct(){$this->middleware('auth');}publicfunctionind...
You cancreate pwa with laravelin minutes by using Laravel PWA. Step 1:Use the following command to install the package: composer require ladumor/laravel-pwa Step 2:In the provider section of the app.php config file, add Service Provide. If you installed it on Laravel 6 or later, you may...
After confirming that you have valid data in your test table, you can exit the MySQL console: exit Copy You’re now ready to create the application and configure it to connect to the new database. Step 3 — Creating a New Laravel Application ...
Why would you use Laravel back-end?Laravel provides a rich set of features out-of-the-box, including a powerful Object-Relational Mapping called Eloquent, an expressive query builder, routing, middleware, authentication, and authorization systems. These features allow you to focus on building your...
* Create a new controller instance. * * @return void */ publicfunction__construct() { $this->middleware('auth'); } publicfunctionfileUpload(Request$request) { $this->validate($request,[ 'video'=>'required|mimes:mp4,avi,asf,mov,qt,avchd,flv,swf,mpg,mpeg,mpeg-4,wm...
Let’s make a small change to dump all the users in the database, so that we can actually see multi-tenancy working. Add this to the middleware group: Route::get('/', function () { dd(\App\User::all()); return 'This is your multi-tenant application. The id of the current tena...