CodeCharge Studio
search Register Login  

Visual PHP Web Development

Visually Create Internationalized Web Applications, Web Reports, Calendars, and more.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> PHP

 filtering directory data

Print topic Send  topic

Author Message
mavtech

Posts: 133
Posted: 06/03/2004, 11:50 AM

I would like to filter the directory data based on the category_id.

I am trying to use the SubcategoryLink.
I have change the control Souce type to "Database Expression"

And what I want to do is use the current category_id to filter which subcategories are displayed.

Select sub_category_name from sub where sub_category_id = {category_id}

I am not an sql expert in the least and I can't seem to get it working.

End result would be a directory that only shows subcategories for currently chosen category.

Paul
View profile  Send private message
peterr


Posts: 5971
Posted: 06/03/2004, 2:36 PM

Possibly I misunderstood your question but this seems to be the standard functionality of the Directory Component and shouldn't require any changes.
For example if you go to http://examples.codecharge.com/ExamplePack/Directory/Directory.php and select the Category "Automotive" then you will arrive at the page http://examples.codecharge.com/ExamplePack/Directory/Di...p?category_id=1 , which lists only the subcategories for the selected "Automotive" category. Or if you drill down the categories to the "Computers and Internet > Software" category, then you will see a grid that displays only the records for the selected category/subcategory.
I'm not sure if you had problems with replicating any of this functionlity? For the Directory itself or the Grid?
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com
View profile  Send private message
mavtech

Posts: 133
Posted: 06/04/2004, 6:22 AM

her is what I am sort of looking for:

Automotive
Subcat 1
Subcat 2
Computers
Subcat 1
subcat 2

but when I hit automotive i get
Automotive
Subcat 1
Subcat 2
Computers


Notice no subcat on Computers.

I am after that when I hit Automotive from the directory current category_id would change. Then in the program it would filter to only show top items as well as only subcategories with parent category equal to current category.

Paul
View profile  Send private message

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

MS Access to Web

Convert MS Access to Web.
Join thousands of Web developers who build Web applications with minimal coding.

CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.