It seems like the issue could be related to caching.
How to identify the problem
If you are using Chrome, Firefox, or Safari, you can right-click on the page and select inspect element
, then go to the network
tab.
When you refresh the page, you will see all the HTTP requests and their statuses.
A status of 304 for a CSS file means that the browser asked for the file but the server responded that it hasn't changed.
A status of 200 with the size from cache
means the browser is using a cached version of the file without checking with the server.
If you are experiencing the latter scenario (200 from cache), continue reading for solutions.
How to resolve this issue:
You can clear the browser cache or disable it temporarily for debugging purposes.
However, asking visitors to do the same is not practical, so consider the following method instead:
If you are using a server-side language like PHP, you can append a query string to the CSS file name:
<link rel="stylesheet" type="text/css" href="http://www.example.com/style.css?ts=<?=time()?>" />
In most cases, this approach will work effectively.
If the page is static HTML, you can manually change the CSS query string (or even the file name) to force the browser to fetch a new version.