PDA


View Full Version : Need advise... How to get Alpha ordering and search for Cats and Directories?


Quarterbore
02-06-2006, 10:51 PM
I am sure I can figure it out if I spend enough time but can someone give me a clue how I can pull a list of Sub categories or Directories that fall under a parent...

For example:

At root of Links I have:

Cat 1
>> Sub Cat 1
>>>> Dir 1
>>>> Dir 2
>>>> Dir 3
>> Sub Cat 2
>>>> Dir 1
>>>> Dir 2
>>>> Dir 3
>> Dir 1
>> Dir 2

I would like to work up a script that can look at the Sub Catagories and Directories that are children to the Category I am in and then search them by the first leter like the [a] [b] [c] that we have now for listings.

We are still developing our Links Directory but you can start to get a feeling for why I need this when you see my use of the links directory here:

http://www.timeshareforums.com/resorts/index.php

Just imagine you wanted to find a Resort in Killington Vermont, USA and look at how difficult it is to work your way down the levels...

Brian
02-07-2006, 03:07 PM
Unfortunatly I think something like that is going to take a bit of work and some knowledge about PHP.

Quarterbore
02-10-2006, 01:10 PM
Yea, it is a trick but thankfully the Links database is laid out with Cat, Parent Cat, and a Family list of Cats so this is manageable...

I have put this project on hold as I had other site fixes I needed to get done because of the the upgrade to vb 3.5.3 but it seems the data in vba links is ordered very nice in the database to make it easy for us to work with the data... For that I am thankful....

Well, with one critism... Why in the world was it decided to seperate the "links" table from the "custom fields" table? It seems like they are a one to one relationship (row wise) but it sure would have been nice if custom fields could have been tacked into the same table as the links to make sure that the alignment was the same.

Perhaps there were size issues?

Brian
02-10-2006, 05:08 PM
Well, with one critism... Why in the world was it decided to seperate the "links" table from the "custom fields" table? It seems like they are a one to one relationship (row wise) but it sure would have been nice if custom fields could have been tacked into the same table as the links to make sure that the alignment was the same.

Perhaps there were size issues?
Well, one reason is it's easier to manage that way. Another is the fact that you don't always need the custom field info (browselinks.php for example), so pulling the info from a smaller table makes things easier on the server.