0

Is there a way to add a class to the body element if there are one or more items in a shopping cart?

I'm using Drupal 7.38 and Commerce 7.1. I have to admit that I haven't tried anything to achieve my goal, apart from searching the interwebs - I have no idea how to add a class when a certain event happens.

3
  • Related (possibly duplicate): drupal.stackexchange.com/questions/70741/…. Please let me know if that solves your problem
    – Clive
    Jun 26 '15 at 16:08
  • @Clive Thanks for the link. I guess it answers my question, albeit in a very minimal way ("it's possible with rules and these modules"). It didn't get me very far ;(.
    – rkhff
    Jun 26 '15 at 16:39
  • Worth a shot :) Might be a good idea to edit this question and add "I understand it's possible with the context module, but how?" or similar, it may encourage a more thorough answer
    – Clive
    Jun 26 '15 at 17:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.