It sounds like you're trying to do too many things at once.  If you create a
form to accept entries, process the entries when the form is submitted.
Check each entry and only add ones that don't already exist in the database.
After that, if you want to display results, start at the beginning of the
array from the submitted form and pull information from the database  for
each entry - by this point every one of them should have an account and it's
just a matter of listing their information... Sorry, rambling a little
here... did that all make sense?

-----Original Message-----
From: Chad Day [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, July 09, 2002 1:22 PM
Subject: [PHP] multi dimensional arrays / radio buttons / mass confusion
on my part

Ok.. what I have is a database of first names and last names, and some other
columns that don't matter here.

A form is presented to a user, lets them enter a bunch of names, attributes
of the person, etc.

After submission, each record is checked against the current database to see
if the name currently exists, or names similar to it exist.

If so, it gives the option of either:

a) entering the new record
b) selecting one of the existing records


Enter your names, positions:
Joe Schmoe, LW
Random Guy, RW

(submit button)

After DB check for existing users:


()  Joey Schmoe   Click radio button to se this record
()  Create New Record

No matches found for Random Guy, must be a new user.

(submit button)

My problem is keeping this data consistent form by form, and updating the
data when an existing record is selected instead of creating a new one (the
existing data needs to go into another table, so I need to grab the user id
# of the existing record, etc)

Any thoughts on how to approach this?  After the first form, should I make a
multi-dimensional array, and have the second form update/change the elements
of it?  I haven't used any PHP arrays in this yet, just been messing with
the HTML form array stuff..

Sorry if this is confusing.. if any part needs clarification, please let me


PHP General Mailing List (
To unsubscribe, visit:
This message is intended for the sole use of the individual and entity to
whom it is addressed, and may contain information that is privileged,
confidential and exempt from disclosure under applicable law.  If you are
not the intended addressee, nor authorized to receive for the intended
addressee, you are hereby notified that you may not use, copy, disclose or
distribute to anyone the message or any information contained in the
message.  If you have received this message in error, please immediately
advise the sender by reply email and delete the message.  Thank you very

PHP General Mailing List (
To unsubscribe, visit:

Reply via email to