For Programmers: Free Programming Magazines  


Home > Archive > PHP Pear > March 2005 > DB_DataObject_FormBuilder for many to many table?









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author DB_DataObject_FormBuilder for many to many table?
Brett Bieber

2005-03-30, 8:57 pm

I'm looking for an easy way to generate a spreadsheet with checkboxes
(checked indicating a record exists) from a many to many table.

Has anyone done something like this before?

From the documenation for the api: "The crossLinks array holds data
pertaining to many-many links. If you have a table which links two
tables together, you can use this to automatically create a set of
checkboxes on your form."

which seems to say that this is easy to accomplish... A form with
drop downs (select/option pairs) for each relation is easily possible,
but I can't figure out how to build an array of checkboxes.

For example the first row would contain all records from table1, and
the first column would contatin all records from table2... and if
there were a record in the relationship table for
table1.key,table2.key, a form checkbox would be checked in the
corresponding cell.

Any ideas?
tia...

--
"The web must remain a universal medium open to all and not biasing
the information it conveys," - TBL
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com