[FX.php List] Posting an array help

William Downs william.downs at gmail.com
Mon Oct 22 09:28:24 MDT 2007


Hi there guys,

Headbanging the key board now ! Perhaps someone has already done this.

The user selects a record - this record has child records.
I allow the user to check box select any number of child records.
I then POST the array to the next page
The next page runs an FMFind for the original DB values

if there are new values in the POSTed array, they should be created
(FMNew) in the child table
If they are not in the POSTed array, it means that they have been
deselected, and should be deleted in the child table.

Here is where it falls flat - ($vlAoE is the POSTed array and
$medAoEData is the array from the DB)

if(!in_array($vlAoE,$medAoEData)) {
               //It should  create the new values here
} else {
             if(!in_array($medAoEData, $vlAoE,)) {
               //It should delete the old values here
}
}

Probably obvious what I have done wrong - but any advice more than appreciated.

Regards

William

-- 
William Downs
Development and Support
BD Databases Ltd


More information about the FX.php_List mailing list