Create Treeview with jsTree plugin and PHP

If you already managing the relationship between parent and child items using a separate field then it is easier to create a hierarchical structure.

With the use of a jsTree plugin, this will be created in less time.

jsTree is a jQuery plugin that creates a hierarchical data structure using JSON data.

It allows setting icon of a node, by default open, disable a node and set it selected while initializing, etc.

In this tutorial, I show how you can make a tree structure of MySQL data using jsTree plugin and PHP.

Create treeview with jsTree plugin and PHP

Read more

How to add Download Link in Dropzone – PHP

Dropzone is easy to set up on the page and upload files using Drag & Drop or file browse.

File preview display after file upload.

It allows you to add or remove file link using addRemoveLinks option but there is no option for adding a Download link.

In this tutorial, I show how you can add a download link with file thumbnail in the Dropzone container with jQuery and PHP.

How to add Download Link in Dropzone – PHP

Read more

Check Username Availability with AJAX PHP and PDO

On the website, there must be a unique identifier for each user. It can be the username, email-id or any string using which user can log in to the website and access it.

Before adding the user using the registration form it must be check if the username is available or not.

This can either done after submitting the form or using jQuery AJAX to display availability status before submitting the form.

In this tutorial, I show how you can check username already exists or not in the MySQL database table using jQuery AJAX PHP and PDO.

Check username availability with AJAX PHP and PDO

Read more