Getting Data In

How do I reload CSS and JS files despite the browser cache?

matthieumarrast
Explorer

Hello,

I source CSS and JS files in my view, as below:

<form stylesheet="style.css" script="script.js">

But, each time I make modifications, the files are not reloaded (because of browser cache) and our modifications are not visible to the users. How can I do this? Clearing the cache is not an easy action for end users.

I tried

<form stylesheet="style.css?v1.0" script="script.js">

but it does not work.

0 Karma
1 Solution

493669
Super Champion

easiest way is to bump the server-

https://<SH>:8000/en-US/_bump

Click that button. Every click increases the bump, which effectively breaks all caching in the webserver. No need to restart! If you find it doesn't work as expected, run also the debug/refresh endpoint.

 https://<yourSplunk>/debug/refresh

View solution in original post

mstjohn_splunk
Splunk Employee
Splunk Employee

Did the answer below solve your problem? If so, please resolve this post by approving it!
If your problem is still not solved, keep us updated so that someone else can help ya. Thanks for posting!

0 Karma

matthieumarrast
Explorer

Yes. It seems to be ok.

0 Karma

493669
Super Champion

easiest way is to bump the server-

https://<SH>:8000/en-US/_bump

Click that button. Every click increases the bump, which effectively breaks all caching in the webserver. No need to restart! If you find it doesn't work as expected, run also the debug/refresh endpoint.

 https://<yourSplunk>/debug/refresh
Get Updates on the Splunk Community!

Introducing the Splunk Community Dashboard Challenge!

Welcome to Splunk Community Dashboard Challenge! This is your chance to showcase your skills in creating ...

Built-in Service Level Objectives Management to Bridge the Gap Between Service & ...

Wednesday, May 29, 2024  |  11AM PST / 2PM ESTRegister now and join us to learn more about how you can ...

Get Your Exclusive Splunk Certified Cybersecurity Defense Engineer Certification at ...

We’re excited to announce a new Splunk certification exam being released at .conf24! If you’re headed to Vegas ...