> The bit I don't see is how you get the info about section navigation
> into the context - is it hard-coded into the view? This is what I'd
> like to avoid.

Ah. The short answer is: sort of.

The breadcrumbs are a straight computation.
The nav bar was done by CSS class manipulation, where the class name
was modified if we were in that section. The nav bar for this site was
moderately complicated (I love clever designers) and we used this
trick in several places to tweak the appearance.

Something like the following (only more complicated, involving
changing background images, etc.):

In the stylesheet:
  div.nav {  color: black;  background-color: white; }
  div.nav-active {  color: red;  background-color: yellow; }

In the context we would set a variable to "-active" to indicate which
section we were in.
  {..., 'tab2': "-active", ... }

In the template:
  <div class="nav{{tab1}}">Tab1 nav stuff</div>
  <div class="nav{{tab2}}">Tab2 nav stuff</div>

It was a small pain setting it up, but once you have it you don't care
what the *&[EMAIL PROTECTED] designer comes up with! :-)

  HTH, Peter

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to