Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Im developing a website. I dont have a local environment, my text editor FTPs files to the server. I want CSS changes to update on the webpage without me having to keep refreshing the page. Is there a plug in or javascript code that will refresh the CSS on a web page every second or half second?

I know there are lots of browser plugins like live reload but I have some trouble getting these to work at the best of times, and as im not working locally I dont think any of them will work for me.

share|improve this question

closed as off-topic by ChrisInEdmonton, Shekhar, mpy, Simon Sheehan, Marcks Thomas Oct 20 '13 at 13:35

  • This question does not appear to be about computer software or computer hardware within the scope defined in the help center.
If this question can be reworded to fit the rules in the help center, please edit the question.

    
Yikes. The only time I update code on a production server is if it is absolutely required. Even then, I know exactly what changes needs to be made and will update my version control with the made changes. If your computer is able, I would suggest using VirtualBox to create a development environment that somewhat matches your production environment. Do any testing there and manually refresh your page. This is just my opinion. –  kobaltz Oct 18 '13 at 14:20
    
I normally work locally its just in this instance that I cant. Its a development server not the live site, but its not on my local computer and I have limited control over it. –  jdln Oct 18 '13 at 14:46
    
possible duplicate : stackoverflow.com/questions/2024486/… –  Shekhar Oct 18 '13 at 14:58

2 Answers 2

up vote 1 down vote accepted

I've never tried this before but it looks like this JS tool might work:

http://cssrefresh.frebsite.nl/

Note: Only CSS-files included before the CSSrefresh-file will be refreshed.

share|improve this answer

Use this javascript to reload every 1 second

<script type="text/JavaScript">
function refreshTimer() {
    setTimeout("location.reload(true);",1000);
}
</script>
</head>
<body onload="refreshTimer();">

</body>
</html>
share|improve this answer
    
My page takes a while to refresh so I need to just refresh the CSS not the whole page. –  jdln Oct 18 '13 at 14:47
    
if you have only a portion of the page that uses the css, make the onload call in the div tag of that section –  Shekhar Oct 18 '13 at 14:53
    
The entire page will be being developed. Is it possible to refresh the CSS without the entire page with JS? –  jdln Oct 18 '13 at 15:39

Not the answer you're looking for? Browse other questions tagged or ask your own question.