In this Example, youll learn how to deal with DataList control in HTML5 using PHP. The control gives pretty easy search instead of drop-down in HTML. The aim is to fetch matching records which are set in the form of options in DataList. In this example you can see pretty easy to fetch countries data from MySQL table. The data will be then bounded to DataList control of HTML5.

The aim is to reduce jQuery relevant search with the help of DataList control. Follow the steps carefully to understand how to use DataList control in HTML5 using PHP and MySQL. To run the example, you need to have a MySQL table with some dummy content. I have already given MySQL table with dummy data which makes you to practice this example easy.

Stpes to use DataList Control in HTML5 with PHP

Step 1 : Create a table in MySQL. (countries is the example table name here)