Posted by pablo k on 09/28/70 11:40
changing/updating a record in a mysql table using array(s)
The idea is reading the small table into an array (1). Making a
choice by way of a select field in a form. Publishing the chosen
record in another form.
Then change one or more fields in the form. Sending the form by
POST and then start checking for changed fields by way of
comparing the array to the POSTed fields to build the 'UPDATE
table SET fields' string.
I run into two problems.
(1) I have the multidim $records[x][y] array and want to assign
the chosen record to a simple array $record.
- is this the right way: $record = $records[x] ??
(2) Do I need to send this simple array $record as a hidden field
to have access to it after the form is posted?
tia
pablo k
[Back to original message]
|