Add CSV Excel PDF Export buttons in Yajra DataTables – Laravel

DataTables allows to export data in multiple formats like – CSV, Excel, and Pdf. This is not by default enabled.

Required including some more libraries to start using it.

In this tutorial, I show how you can add export buttons in Yajra DataTable in Laravel 9.

I am assuming you have already installed and set up the Yajra DataTable package if not then you can view this tutorial.

Add CSV Excel PDF Export buttons in Yajra DataTables - Laravel

Read more

Make Reusable queries using Query Scope in Laravel

In Laravel with the use of scope in Model, you can save time of writing the same script in multiple places in your project.

For example, selecting records based on their status – active/inactive/suspended.

The query scope methods are prefixed by scope.

In this tutorial, I show how you can create a reusable query using Query scope in Laravel 9.

Make Reusable queries using Query Scope in Laravel

Read more

How to Auto populate dropdown using Livewire – Laravel

If you are using Laravel for your web development, then you may have come across a requirement to auto-populate a dropdown with the database data.

For example, you may have a form with a country field and you want to auto-populate the states field on the form based on the country selected by the user.

In this article, I show how to auto-populate a dropdown using Livewire in Laravel 9.

I am hoping you have already installed Livewire on your project if not then you can view my previous post for installation.

How to Auto populate dropdown using Livewire - Laravel

Read more

How to Autocomplete textbox using JavaScript and PHP

Autocomplete textbox helps the user to pick an item from the suggestion list based on the input. It occupies less space on the page.

Data is not preloaded on the page. When the user types any character then data is loaded using AJAX.

In this tutorial, I show how you can create autocomplete textbox with MySQL database data using JavaScript and PHP.

How to Autocomplete textbox using JavaScript and PHP

Read more