I have a table(1) with a table(2) and this table has a form. This form is intended to be used to sort out items in their groups. This page was build to loop and this looping causes the page to so separate items in their groups.
Because of the way this page was designed, it needs to have a button to update individual row instead of all the records on the table. Anyways, I create a form(2) within the table but because of the way the page was build (not by me), it wouldn't put the contents I want in a form.
I was thinking of using OOP to write a function and have the func. pass anything in a row to button.
e.g. $page->main .= '<td><button value="' . $value . '_' . $domain . '_' . $acayear . '_' . $desc . '" type="submit" id="no" name="insert_Product">Update</button></td>'; and I used explode to separate whatever the function pass to the button before I run an UPDATE statement.
I have no idea if this is possible with OOP because I am still at the beginning stage of learning it. If this is possible. How will I go about doing it.
Summary:
Pass the variables from the select options and input to an OOP class and pass those variables stored in the OOP class to a button which will then separate using PHP explode before updating a table.
I have use PHP explode before but is the OOP class function that I haven't. I am asking two questions here: If the method I am thinking is possible and if so, how will I start writing this code.
I am sorry I haven't post an OOP example code because I have no idea on how to know using it with this method.