"You are here" navigation
Moderator: General Moderators
-
magicrobotmonkey
- Forum Regular
- Posts: 888
- Joined: Sun Mar 21, 2004 1:09 pm
- Location: Cambridge, MA
- NewfieBilko
- Forum Contributor
- Posts: 189
- Joined: Sun Jun 06, 2004 6:45 pm
- Location: Newfoundland
- Contact:
- NewfieBilko
- Forum Contributor
- Posts: 189
- Joined: Sun Jun 06, 2004 6:45 pm
- Location: Newfoundland
- Contact:
-
theperfectdrug
- Forum Newbie
- Posts: 24
- Joined: Tue May 25, 2004 10:15 am
- NewfieBilko
- Forum Contributor
- Posts: 189
- Joined: Sun Jun 06, 2004 6:45 pm
- Location: Newfoundland
- Contact:
- NewfieBilko
- Forum Contributor
- Posts: 189
- Joined: Sun Jun 06, 2004 6:45 pm
- Location: Newfoundland
- Contact:
-
theperfectdrug
- Forum Newbie
- Posts: 24
- Joined: Tue May 25, 2004 10:15 am
sure.or just send me your source LOL
copy and paste...
Code: Select all
<?php ?>- NewfieBilko
- Forum Contributor
- Posts: 189
- Joined: Sun Jun 06, 2004 6:45 pm
- Location: Newfoundland
- Contact:
-
theperfectdrug
- Forum Newbie
- Posts: 24
- Joined: Tue May 25, 2004 10:15 am
not yet. I've decided to search php forums over the net to find some info about breadcrumbs...so i'm still in search, maybe u'll do the same and together we will find somethin that will help us both.Have you implimented any of there code yet?
I found some useful links so if you are interested I can send them to you.
-
magicrobotmonkey
- Forum Regular
- Posts: 888
- Joined: Sun Mar 21, 2004 1:09 pm
- Location: Cambridge, MA
-
theperfectdrug
- Forum Newbie
- Posts: 24
- Joined: Tue May 25, 2004 10:15 am
- NewfieBilko
- Forum Contributor
- Posts: 189
- Joined: Sun Jun 06, 2004 6:45 pm
- Location: Newfoundland
- Contact:
I have the following table for category/sub category :
CategoryID - int
Title - varchar
ParentCatID - int
CategoryID | Title | ParentCatID
---------- ------ ---------
1 | Foo | 1
2 | Foo Child | 1
3 | Foo Child Child | 2
I would like to dynamically create a list of links at the top of each page that will reflect how deep into the site the user is and give the user the ability to click on a link to return several layers back
For example if i have reached the Foo Child Child category, the navigation should display :
Home > Foo > Foo Child > Foo Child Child
(Home is a constant which can be hardcoded)
Any idea of a code or pseudo how i can do this loop. Bear in mind that each time i load the page i can get the CategoryID of the page i am in.
CategoryID - int
Title - varchar
ParentCatID - int
CategoryID | Title | ParentCatID
---------- ------ ---------
1 | Foo | 1
2 | Foo Child | 1
3 | Foo Child Child | 2
I would like to dynamically create a list of links at the top of each page that will reflect how deep into the site the user is and give the user the ability to click on a link to return several layers back
For example if i have reached the Foo Child Child category, the navigation should display :
Home > Foo > Foo Child > Foo Child Child
(Home is a constant which can be hardcoded)
Any idea of a code or pseudo how i can do this loop. Bear in mind that each time i load the page i can get the CategoryID of the page i am in.
root/level1/section2/layer3/chapter4
If you have the ID of chapter4, then you need to query the database to find the parent of chapter4, layer3. You then need to query to find the parent of layer3, and so on as you move up the tree. In this example, it would require 4 queries (assuming the root level is hard coded).
Last edited by NewfieBilko on Thu Jul 08, 2004 1:51 pm, edited 1 time in total.
- NewfieBilko
- Forum Contributor
- Posts: 189
- Joined: Sun Jun 06, 2004 6:45 pm
- Location: Newfoundland
- Contact: