Support » Plugin: Events Made Easy » Put category slug in calendar listing code

  • Resolved cmerrick

    (@cmerrick)


    Hi! A client of mine is using Events Made Easy for her dog training class calendar:
    https://loveofdogsrwc.com/calendar/

    She’s asked if we can style different categories of classes in different colors. With the right hook in the HTML this is easy. I know I can use #_EVENTCATEGORIES_CSS in the “Full calendar events format” field, but because her category names have spaces in them, this has some issues; I need ‘Advanced I’ to be distinguishable from ‘Advanced II’ and from ‘Intermediate I’. Is there anyway to put the category slug, and not name, in the code?

    I thought of using the category description, but that seems like a weird workaround, and perhaps I am just not seeing a slug option. Many thanks!

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Franky

    (@liedekef)

    For the moment the category name should be used. But can’t you just replace the space by an underscore there?

    Thread Starter cmerrick

    (@cmerrick)

    I could but we may want to display category names on the front end, so that would look weird. Since the slug is by definition unique, machine-friendly, and devoid of spaces, it seems like a better choice for a CSS hook.
    Thank you for the reply!

    Plugin Author Franky

    (@liedekef)

    Well, currently the categories don’t have a slug, so that’s not possible (yet).
    For now I’d suggest to use the category name and on the frontend use the category description if needed.

    Thread Starter cmerrick

    (@cmerrick)

    Thanks for the reply! I ended up doing it the other way around, since I’m 99.9% sure we won’t be using the description on the front end. I explained what I did to the next poster in this support forum, since they’re trying to do the same thing I am 🙂

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Put category slug in calendar listing code’ is closed to new replies.