Title: Don&#039;t cache the HTML Elements&#039; Classes
Last modified: August 30, 2016

---

# Don't cache the HTML Elements' Classes

 *  [Mehedi](https://wordpress.org/support/users/imehedidip/)
 * (@imehedidip)
 * [10 years, 9 months ago](https://wordpress.org/support/topic/dont-cache-the-html-elements-classes/)
 * Hi,
 * I love this caching plugin. However, I’m building a theme switching (dark, light)
   feature for one of my personal sites. As the site’s being cached, there doesn’t
   seem to be any way of making this possible via an HTML Class.
 * So how the feature works is that basically, by default, it won’t have any options(
   will show default light theme). But once the user changes the dropdown option
   to Dark theme (saved to a Cookie), it’ll change to dark mode. I will check the
   cookie via jQuery and a class to the `<body>` tag.
 * So is it possible to disable caching for the HTML Elements’ classes? Or is there
   any workaround for this?
 * Please help – it’s much appreciated, and thanks for this great plugin!
 * [https://wordpress.org/plugins/wp-super-cache/](https://wordpress.org/plugins/wp-super-cache/)

The topic ‘Don't cache the HTML Elements' Classes’ is closed to new replies.

 * ![](https://ps.w.org/wp-super-cache/assets/icon-256x256.png?rev=3506220)
 * [WP Super Cache](https://wordpress.org/plugins/wp-super-cache/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-super-cache/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-super-cache/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-super-cache/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-super-cache/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-super-cache/reviews/)

## Tags

 * [cache](https://wordpress.org/support/topic-tag/cache/)

 * 0 replies
 * 1 participant
 * Last reply from: [Mehedi](https://wordpress.org/support/users/imehedidip/)
 * Last activity: [10 years, 9 months ago](https://wordpress.org/support/topic/dont-cache-the-html-elements-classes/)
 * Status: not resolved