Let's Get Started with an Advanced PHP/MySQL Table Page!
Open Notepad++
Choose: File -> New
Copy the PHP Table Template (PHP) code (below)
Paste that code into your new file
Change the put-title-of-this-page-here
Change each of the <th> lines to add these lines: <th>
<a href="$PHP_SELF?orderBy=dish_name">
<i class="material-icons">arrow_drop_up</i></a>
Dish
<a href="$PHP_SELF?orderBy=dish_name DESC">
<i class="material-icons">arrow_drop_down</i></a>
</th>
For the first column add these lines between the <td> and </td> tags: $table .= " <a href=\"mysqlform2.php?action=mod&id=$id\">";
$table .= " <i class=\"material-icons\">create</i></a>";
$table .= " <a href=\"mysqlform2.php?action=del&id=$id\">";
$table .= " <i class=\"material-icons\">delete_sweep</i></a>";
Add these lines to add an anchor tag for adding a record: $table .= "<p><a href=\"mysqlform2.php?action=add\">";
$table .= " <i class=\"material-icons\">add_box</i></a> new record</a>";
Click: File -> Save As
Name your file: \www\table.php
Change the Save as type: to: PHP Hypertext Preprocessor (*.php)