I think it's the cache problem.
How to locate the problem
If you are using Chrome or Firefox or Safari, just right click on the page and choose inspect element
, and choose network
tab.
Now refresh your page as usual, and you'll see all http request like this:
If the css file status is 304, means browser ask the server the css file, and server says: "no, you don't need to ask me, I gave you the css file before, it has not changed."
If the css file status is 200, but the size is from cache
, it means the browser do not even ask the server for the file, the browser think he has the newest file.
I think you are in the second condition(200 from cache).
How to solve this:
you can always clear the browser cache to see the changes. Or you can disable browser cache for debugging purpose.
But you can't always tell your visitors to clear the cache, so the second method:
if you are using PHP or whatever as server language, append a query string to the css file name:
<link rel="stylesheet" type="text/css" href="http://www.example.com/style.css?ts=<?=time()?>" />
99% of the time, this will work.
if it's a static html page, you can change the css query string manually(or even the css file name, if you like).