Problem with delete row | Formidable Plus | Forum

This forum requires Javascript to be enabled for posting content


Current User: Guest
Please consider registering

Lost Your Password?

Search Forums:


Minimum search word length is 4 characters – Maximum search word length is 84 characters
Wildcard Usage:
*  matches any number of characters    %  matches exactly one character

Problem with delete row

Reply to Post
Add a New Topic
User Post

12:12 am
February 11, 2013



posts 11

Post edited 12:13 am – February 11, 2013 by WendyPorter


I have the following issue, I use a dynamic table (no rows initially) with 4 columns (first three are select, last one is a text field). When I add rows and submit everything seems fine. Here is an example of $_POST for 3 rows:

[“item_meta”]=> array(1) { [147]=> array(3) { [0]=> array(4) { [0]=> string(4) “Head” [1]=> string(11) “Code” [2]=> string(3) “A12″ [3]=> string(10) “02/01/2013″ } [1]=> array(4) { [0]=> string(0) “” [1]=> string(0) “” [2]=> string(0) “” [3]=> string(10) “02/02/2013″ } [2]=> array(4) { [0]=> string(4) “Neck” [1]=> string(3) “etc” [2]=> string(5) “A1234″ [3]=> string(10) “02/03/2013″ } } }

This is as expected. Three entries in item_meta[147] with 4 fields each (i.e. array(4)). Now let's take a look at the same $_POST, if I delete the second row:

[“item_meta”]=> array(1) { [147]=> array(3) { [0]=> array(4) { [0]=> string(4) “Head” [1]=> string(11) “Code” [2]=> string(3) “A12″ [3]=> string(10) “02/01/2013″ } [2]=> array(3) { [0]=> string(4) “Neck” [1]=> string(3) “etc” [2]=> string(5) “A1234″ } [1]=> array(1) { [0]=> string(10) “02/03/2013″ } } }

That ain't right… I still have three entries in item_meta[147] and they are incomplete. First row [0] is fine. Second row [2] is not reindexed properly and is missing the last column value. And the last column value from the deleted row [1] appears as the last item [1] which should not be there…

What causes this issue? How can it be fixed?

Thank you and regards.

12:47 pm
February 13, 2013



posts 11

It seems that the problem is that only <input type=”text”> and <textarea> elements are reindexed when a row is deleted.

I fixed it using the delete_row event that is triggered and applied the reindexing to <select> elements as well. This has to be done for all element types in the row. The right fix would be to apply the class .table-cell to all field types. This would be achieved by modifying the table-field.php file to assign the .table-cell class to all element types in the switch statement.

I did not feel like modifying the plugin code so I decided to use the triggered event instead.

Obviously, the proper fix in table-field.php should appear in the next release of this plugin.



5:13 pm
February 24, 2013

Top Quark


Hi Wendy,

Apologies for being absent.  I've had way too much going on over the last couple of months and am just barely re-emerging. 

I'm going to look into this issue and see if I can still reproduce it.  It might have been resolved in the latest Formidable Plus – 1.1.8 just released today to fix another critical and (too long) standing bug.


10:41 am
February 25, 2013

Top Quark


Hi Phil,

Oh boy, it's been a Formidable Plus sort of 24 hours!  

I had a chance to look into your issue and thanks for your help in debugging it.  That was indeed the issue.  I've coded the fix and it is released in Formidable Plus  


Reply to Post

Reply to Topic:
Problem with delete row

Guest Name (Required):

Guest Email (Required):

NOTE: New Posts are subject to administrator approval before being displayed

Post New Reply

Guest URL (required)

Math Required!
What is the sum of:
6 + 1

© Simple:Press