Skip to content
Advertisement

adding a delete button in php

I have created a table of items that are in my DB, it comes out perfectly however I would now like to add a delete button in another column of the data I am outputting.

However I am just not sure how to do it, I do have a uniqueid for each of the tables so could I use that as the id or what ever you would call it of the button?

JavaScript

any help would be appreciated.

Advertisement

Answer

Before your table:

JavaScript

and close the form tag after your table.

Place this code as your delete button:

JavaScript

In PHP you should do the following

JavaScript
User contributions licensed under: CC BY-SA
1 People found this is helpful
Advertisement