There's probably a better way to do this, but I'm new
to rails so any help appreciated.
I'm not sure if this is what you're looking for, but views get
'knowledge' of their 'source' via controller.controller name and
So you can do:
if controller.controller_name == 'foo'
# ... show something specific to foo
elsif controller.controller_name == 'bar'
# ... show something specific to bar
If you want to make the code specific to both controller and action you
if controller.controller_name == 'foo' && controller.action_name ==