Automatically expand sections on rails site based on url parameters
===

I have a rails page that has multiple sections that load closed, but can be opened by clicking on a corresponding link. I want to be able to expand all (or some) of these sections based on a permalink. In other words, I want to somehow click specific links on the page depending on what the url parameters are. What's the right approach to doing this?