On Dec 18, 10:45 am, Martin DeMello <martindeme... / gmail.com> wrote: > On Dec 18, 2007 11:00 PM, Phrogz <phr... / mac.com> wrote: > > > > > This website has a menu of industries, a menu of categories, and a > > menu of products. > > If a single industry is selected, highlight the categories and > > products are available for that industry. > > If a single category is selected, highlight the industries and > > products are available for that category. > > If a single product is selected, highlight the industries and > > categories available for that industry. > > If a pair of items is selected (for example, one industry and one > > product) show all the related items that match the intersection (for > > example, all the categories that apply to the intersection of those > > two choices). > > Use a database - they're written to solve this exact problem! What does that look like? Given n tables of entries, you have a single extra table with n columns, where each row enumerates a given possible combination? And then you just query that table to get a flat list of all possible combinations, and then spin through the rows and build up your arrays of possibilities? Not a bad suggestion, and so simple.