views:

387

answers:

2

My categories can be nested about 6 levels deep at most. The problem I am having is getting the breadcrumb array or list from the database (sql server 2005). My sql skills are not that great. Once I get the breadcrumb from the database what would be the best way to present it.

A: 

Why are you storing the users history in the database? Wouldn't a breadcrumb be more of where the user has been?

In that case you'd probably want to store the page each time a user navigates to it, dropping off the first item when you have reached your maximum length.

the issue then becomes one of where to store that history and yeah a database may be an option. You might also want to store that with the users session data if available. there are stacks of ways to implement storage of history.

EDIT

This is added info to what mjv said.

griegs
A: 

There are several ways you could represent breadcrumb information in your markup. There isn't a <breadcrumb> element in HTML so its debatable if any approach is semantically correct. Look here for a discussion of some of the approaches that people use.

I prefer using lists, then you could style it as shown in this example.

DSO