Category: DataBase

A model is a PHP class where perform data logic and database manipulation like – retrieve data, insert, update, and delete.

In Laravel models classes are stored in app/ directory.

This mainly loads from the controller.

In this tutorial, I show how you create and load Model in the controller and fetch records from MySQL database in Laravel.

How to create and load Model in Laravel

DataBase How To Laravel PHP

Live username availability checking on the registration page is the common feature in most of the website.

This will notify the user whether the username is already been taken or not before submitting.

To do this require AJAX.

Send a request to check the username on the bases of response perform the action.

In this tutorial, I show how you can check username availability using Vue.js and PHP.

Check Username Availability with Vue.js and PHP

AJAX DataBase PHP Vue.js

Add, edit, and delete functionality mostly requires on every dynamic based web project.

With AJAX you can improve user experience and do these operations without page reload.

For this, I am using Axios package.

In this tutorial, I show how you can select, insert, update, and delete records from MySQL database with Vue.js and PHP.

Insert Update and Delete records from MySQL with Vue.js

AJAX DataBase PHP Vue.js

Data selection is one of the basic requirement when creating a dynamic website.

Mainly data is fetched from the database on page refresh but for without page refresh require to send AJAX request.

I am using Axios package to send AJAX request.

In this tutorial, I show how you can fetch records from MySQL database using Vue.js and PHP with Axios package.

Fetch records from MySQL Database with Vue.js and PHP

AJAX DataBase PHP Vue.js

Date filter makes easier to list records according to specific date range selection.

The user can pick dates and search the list. Records will be displayed according to date selection.

To add datepicker you can use jQuery UI, Bootstrap, or any other jQuery plugin.

In this tutorial, I am using jQuery UI to add datepicker widget and filter the records with PHP MySQL.

jQuery Datepicker to filter records with PHP MySQL

DataBase PHP

AJAX based pagination load content without reloading the whole webpage and improve the user experience.

CodeIgniter has the pagination library to add pagination.

From the controller need to handle the AJAX request which sends from the view.

In this tutorial, I show how you can create AJAX pagination in CodeIgniter.

How to Create AJAX Pagination in CodeIgniter

AJAX CodeIgniter DataBase How To JQuery PHP

Pagination gets complicated when to find specific groups of records when there is a large number of records are available.

By adding a search filter with pagination makes easier for the user to easily find records e.g. filter list by country, department, name etc.

It is easier to add pagination using pagination library in CodeIgniter.

In this tutorial, I am using the SESSION to store search value and filter the pagination list.

Pagination with search filter in CodeIgniter

CodeIgniter DataBase PHP