The app can have the following URLs:

<li> /projects/ </li>
<li> /projects/3 </li>
<li> /projects/3/photos </li>
<li> /projects/3/photos/312 </li>

I'd like to know how in Rails 3 I can look at the current URL and know
which of the lines above is currently active, so I can add a
class="selected"

Additional exmaple..

If the user's browser is on: /projects

And the Nav looks like

Projects
  - Photos
  - Files

Projects is Active

but if the user's browser is on: /files

Projects is active

and Files is active (they both apply).


Ideas? thanks

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to