Display Online Users in the UI Using Laravel 11, Laravel Reverb & Laravel Echo

As of now you are able to send/receive Real-Time Notifications in Laravel 11 Using Laravel Reverb & Laravel Echo then communicate Securly WebSockets with Authentication in Laravel 11 (Reverb & Laravel Echo) and then you are able to see tha which user is online. Next comes how to see the list of online users.

February 2025 · 2 min · Pavan Kushvaha

Authenticate REST APIs in laravel Step by Step Guide

Hope you have understood that How to implement REST APIs in Laravel, Now you need to make your apis secure to access. To authenticate your Laravel API, we’ll use Laravel Sanctum, which is lightweight and perfect for token-based authentication in REST APIs. Here’s how to implement it

February 2025 · 2 min · Pavan Kushvaha

Implement Presence Channels in Laravel 11 Using Laravel Reverb & Laravel Echo

Presence channels allow you to track which users are online in real-time. This is useful for chat apps, user activity tracking, and more.

February 2025 · 2 min · Pavan Kushvaha

Secure WebSockets with Authentication in Laravel 11 (Reverb & Laravel Echo)

By default, Laravel Reverb allows public and private channels. To secure WebSockets, we need authenticated private channels.

February 2025 · 2 min · Pavan Kushvaha

Implement Real-Time Notifications in Laravel 11 Using Laravel Reverb & Laravel Echo

Since Laravel Reverb is Laravel 11’s built-in WebSocket server, we’ll set it up with Laravel Echo to enable real-time notifications.

February 2025 · 2 min · Pavan Kushvaha

How Socialite Works in Laravel for Authentication

User clicks the “Login with {Provider}” button. 2. Redirect the user to the provider’s OAuth page. 3. User logs in and authorizes the application. 4. The provider redirects the user back to your application with an access token. 5. Use Socialite to retrieve the user’s information and handle authentication in your app.

January 2025 · 2 min · Pavan Kushvaha

Handle events for Eloquent models in Laravel

Laravel’s Eloquent provides several model events that allow you to hook into the lifecycle of a model. These events can be used to execute custom logic when specific actions occur.

January 2025 · 5 min · Pavan Kushvaha

Remove Composer package from laravel

To remove a package from Laravel using PHP Composer, composer remove vendor/package-name and then remove service provider references, clear the cache.

January 2025 · 3 min · Pavan Kushvaha

Automatically delete related records in laravel

In Laravel’s Eloquent ORM, you can automatically delete related rows when a parent model is deleted by defining relationships and cascading delete behavior

January 2025 · 4 min · Pavan Kushvaha

What is middleware in laravel

In Laravel, middleware provides a mechanism to filter HTTP requests entering your application. It acts as a bridge between the incoming request and the application logic. Middleware can be used for tasks like authentication, logging, request modification, or CORS handling. Here’s how middleware works in Laravel

January 2025 · 6 min · Pavan Kushvaha