rails helper css class change -
i have helper function in class shown when specific controller open.
helper:
def cssclass 'class="tab_gen_active3"' if controller_name == "user_brands" end i having difficulty apply 'else' in "tab_gen3" css class activated when controller_name = "user_categories". idea how this.
change to
controller_name == "user_brands" ? 'class="tab_gen_active3"' : ''
Comments
Post a Comment