PHP

Recent Tutorial

Sorting MySQL Column using PHP

March 9, 2016
In PHP we can sort database results based on a column field using MySQL order by clause. Previously, we have seen about how to change the MySQL row order using jQuery. Now, we are going to see an example to sort UI results by clicking on the column name in the header. We have a […]
This tutorial was added to PHP.

PHP Time Ago Function

March 1, 2016
This PHP tutorial is for converting given date into a time ago string like 2 hours age, 3 years ago. In a previous tutorial, we have seen date format conversion by using PHP inbuilt functions. In this example, we are having a custom function to change a date format into time ago string. View Demo […]
This tutorial was added to PHP.

AJAX Cart Edit in PHP Shopping Cart

February 29, 2016
This Shopping cart tutorial is providing cart edit feature by using jQuery AJAX. In a previous tutorial, we have seen simple shopping cart. This edit feature allows changing the existing cart item quantity in session. In this example, we are showing item quantity in a text box to allow edit. This cart edit function is […]
This tutorial was added to PHP.

Responsive PHP Shopping Cart

February 29, 2016
In this tutorial, we are going to create a shopping cart gallery page with responsive design using PHP. In a previous tutorial, we have seen shopping cart with multi tab. With a responsive design, the shopping cart page will be fluid to fit into any viewport. In this example, we are achieving this responsive design […]
This tutorial was added to PHP.

PHP MySQL Date Range Search with jQuery DatePicker

February 14, 2016
In this tutorial, we are going to see how to search database records date between two given ranges. It will return the filtered results from the database based on these dates input. In this tutorial, we are using jQuery DatePicker to choose the dates for the search options. These date inputs are used to form […]
This tutorial was added to PHP.

PHP RESTful Web Service

October 18, 2015
Representational State Transfer (REST) is an architecture style. Web services that follow the RESTful principles are RESTful services. In RESTful services, URIs are used to access the resources. Data and functions are called resources in the RESTful glossary. So eventually data and function are what we will access via services. In this RESTful web services […]
This tutorial was added to PHP.

PHP Cache for Dynamic Web Pages

October 16, 2015
Caching a dynamic web page is very important. When developing a website using PHP, the cache is often overlooked. Cache helps to increase the speed of the website response. In the web, nanosecond performance improvement can make wonders. If your site depends on search engine traffic, then cache should be your foremost priority. Google considers […]
This tutorial was added to PHP.

PHP Shopping Cart by jQuery Drag and Drop

September 20, 2015
In this tutorial, we are going to see a shopping cart example. In this example, we are adding products to cart by using drag and drop. In a previous tutorial, we have seen PHP shopping cart with jQuery AJAX. In this example, we are having draggable product items. We are adding these items to cart […]
This tutorial was added to PHP.

Paypal Payment Gateway Integration in PHP

August 21, 2015
In this tutorial, we are going to see about how to integrate payment gateway in PHP via Paypal. We are going to see an example code in PHP for payment integration. In this example, we are using Paypal sandbox (test) mode to check payment flow before going live. Paypal Payment Integration Steps Login / Sign […]
This tutorial was added to PHP.

Generate PDF from MySQL Data using FPDF

June 8, 2015
In this tutorial, we are going to see how to generate PDF from MySQL table by using FPDF library. In a previous tutorial, we have seen about simple PDF generation from a text file content by using this library. In this example, we read MySQL table data by using PHP. And then we are calling […]
This tutorial was added to PHP.

Shopping Cart with Multi-Tab Wizard using jQuery AJAX

June 6, 2015
In this tutorial, we are going to see a wizard like a shopping cart. In a previous tutorial, we have seen shopping cart with jQuery AJAX. In this wizard-like shopping cart example, we separate products and cart items by using tabs. While adding products, the cart tab is updated with the cart item count. View […]
This tutorial was added to PHP.

PHP PDF Generation using FPDF

May 25, 2015
In this tutorial, we are going to generate PDF from text file data using PHP FPDF library. In this library, there are features to add PDF page, set font, create grid and more. In this example, we are having a text file containing toys detail. We are reading this file content and show it in […]
This tutorial was added to PHP.

PHP Shopping Cart with jQuery AJAX

May 20, 2015
In this tutorial, we are going to create a shopping cart using jQuery AJAX. In a¬†previous tutorial, we have seen simple shopping cart code using PHP without jQuery or AJAX. In this shopping cart example, we can add products to the cart to checkout. Using jQuery we are updating product status in UI whether it […]
This tutorial was added to PHP.

PHP JSON Array Merge

May 14, 2015
In this tutorial, we are going to see about how to merge two or more JSON string. This can be done by decoding given JSON objects and encoding after the merge. In this example, we are having two JSON objects to merge together. These objects will be decoded into an associative array and encoded after […]
This tutorial was added to PHP.

Calculating Hours Difference in PHP

April 15, 2015
In PHP, there are many ways to calculate the difference between two dates. In this tutorial, we are using PHP date time functions to calculate the hour¬†difference between two dates. In this example, we are start and end dates from the user. And then, we use strtotime() to convert the date string into timestamp to […]
This tutorial was added to PHP.

↑ Back to Top