How to PHP Scripting- MySQL Database with phpMyAdmin
A database is a separate application that stores a collection of data. You can create many databases as you want. Each database has one or more distinct APIs for creating, accessing, managing, searching and replicating the data it holds. With PHP, you can connect to and manipulate databases. MySQL is the most popular database system used with PHP.
In this guide, we are using phpMyAdmin to administer MySQL database which is automatically installed with Xampp package. Check our tutorial, how to install and configure Xampp server. PhpMyAdmin is also integrated with Cpanel of your web hosting.
PhpMyAdmin is one of the most popular applications for MySQL databases management. It is a free tool written in PHP. Through this software, you can create, alter, drop, delete, import and export MySQL database tables.
To access phpMyAdmin, open your Web browser and go to http://localhost/phpmyadmin/.
In the upper part, you will find the server hostname. The databases which you will manage are stored on the same server as the software and the hostname is localhost.
In the right column, you can change the default language, alter the style, customize the theme color and the font size.
Create a user account using phpMyAdmin
You can create MySQL user accounts with PHPMyAdmin administration tool and also you can grand customized privileges to users. Let’s look how to create user accounts.
- click on the “Privileges” link.
- Click on the “Add a new User link”.
- Assign User a login and password.
- Where it says “Database for User” select “None”.
- select global privileges to create database.
- Press the “Go” button.
Now we’ve MySQL with username & password. Let’s connect to MySQL server and create a database on next tutorial.