I’m trying to write an admin panel for a website. The functionality I want to code is simple:
there will be a list of projects and next to the project’s name there will be a button called ‘edit’. The button will lead the user to another page where he can edit that specific project.
What confuses me is the fact that I can’t identify which button was pressed unless I check each one of the buttons specifically (am i right?). It would help if all the buttons have the same name and different value rather than different names and same value.
So is there a way to actually tell which project’s button was pressed?
Thanks in advance
Most browsers will send value of
valueattribute ofbuttonelement:But if you need to support older versions of IE, you might use arraylike name
And access it in php: