Can I add a prefix to sprite class names?

You can add the prefix parameter ('p_' in URLs) to add a prefix to the class names created.
For example:

Here's an original sprite:
http://res.cloudinary.com/demo/image/sprite/logo.css

And here's the same sprite when adding the "home_thing_' prefix:
http://res.cloudinary.com/demo/image/sprite/p_home_thing_/logo.css

Have more questions? Submit a request

Comments

  • Avatar
    Thierry Lau

    Hello

    The sprite generation with a custom prefix failed for the css file

    Given the url :

    http://res.cloudinary.com/***/image/sprite/p_pict_/icons.css

    and an uploaded image bonbon.png

    I have a classname p_pict_icons-bonbon generated in the css file.

    There is an unwanted extra "icon-" in the classname

    Best regards

  • Avatar
    Itay Taragano

    Hi Thierry,

    Can you please share the actual file's URL so we'll be able to take a better look at this?
    If privacy is an issue, please feel free to contact us directly at support@cloudinary.com.

    Thanks

Powered by Zendesk