Does anyone know of a way to disable browser refreshing in Codekit 2? I’m enjoying the local server feature, but we have multiple people working on the site, and every time one person changes and saves a file we all get our pages refreshed. I'd like to temporarily disable it.
I know there are other ways for folks to access my site locally, but Codekit is what we're using for this right now.
Simply pause file watching:
Press command + option + control + / to toggle CodeKit's file-watching
on and off.
This stopped auto refreshing for me when I made a change. You can still use codekit's address and it won't refresh when you make a change if you have paused watching.
Related
I made some alterations to a page, and, using Firefox, did a Shift-Command-R to hard reload it. When I do that, Firefox reloads the new page as expected, but if I then do an ordinary page reload (e.g. Command-R) reloads the old version of the page.
I don't get this behavior using Chrome; I only have to do the hard page reload once, and the new version loads from then on with an ordinary page reload. So it doesn't look like this has anything to do with my hosting service (BlueHost).
I've tried:
Clearing the cache, using Firefox/Preferences/Advanced/Network and hitting the "Clear Now" button in the "Cached Web Content" area.
Deleting all cookies associated with the site containing the page.
Quitting Firefox and opening it again.
After doing all of these, I still get the same behavior: Shift-Command-R loads the new version of the page, and Command-R loads the old one.
Firefox version is 52.9.0; MacOS version is 10.13.6.
Can anyone shed some light on why this is happening?
This behavior is by design in FireFox:
Reload F5 (or) command + R
// does not override cache
Reload (override cache) command + shift +
R
// override cache
↳ Keyboard shortcuts - Perform common Firefox tasks quickly
I'm trying to test my game on the site using the simulator page. however I'm running into a problem. no mater what it seems like my page updates are not changing on the simulator. I've tested locally on the pages, and they work fine.
anyone know? i haven't seen anything in documentation
At least for me when I'm testing the controllers for the Unity project, or another HTML / Javascript project I need to clear the cache once in a while to make it work.
For Firefox; Options (top right corner) - Privacy & Security (left menu) - Clear data (button on the right)
(I untick the "Cookies and Site Data" because it does not affect to this problem.)
And just to make it clear, it's not an AirConsole problem. If you have ever tried to create a local website and you are testing stuff this might happen as well. Also, you don't have to do this everytime something changes.
Just found out that if you add something a question mark after the address and put something random after it, it will refresh well again (a bit like what is done in web with images to avoid caching sometimes).
Example:
Original url: http://www.airconsole.com/#http://192.168.1.2/game
Url after 1st change: http://www.airconsole.com/#http://192.168.1.2/game?1
Url after 2nd change: Url after change: http://www.airconsole.com/#http://192.168.1.2/game?2
etc...
UPDATE
I've also found that the following works:
Original url: http://www.airconsole.com/#http://192.168.1.2/game
Open a tab with http://192.168.1.2/game/screen.html
Do CMD + Shift + R on OSX or Ctrl + F5 on Windows when using Chrome
Switch to the original airconsole URL tab and do the previous step
Your game is now refreshed
I have an unusual problem that I can't wrap my head around and figure what is causing this and how to tackle it.
I've created a webpage that allows image uploads to the server! After the user uplaoded an image the host of the page receives an e-mail with the path to the uploaded image - really straight forward.
In the e-mail for instance a url like this is coming in.
https://www.something.com/uploads/FB_IMG_1525868856883.jpg
I can open that in Safari on Mac, I can open that in some cases in Chrome Incogntio, but it never renders in Internet Explorer or normal Chrome Window (in Incognito it does)
In the image you see something weird happening. In Incognito a different source is rendered than in a normal chrome window. (this is btw. not a caching issue)
you also see the page-title of the actual website resolved in the normal window, but not in incognito.
Why is that happening? What could cause that? is that some server setting? Some react setting I have to set?
I'm posting this in case someone else runs into it as well. I ran into this same issue where 500 kept happening for me and I knew it was not the extensions.
What fixed it for me:
Open Developer Tools in Chrome
Navigate to Applications Tab
Click "Clear Storage
Click Clear Site Data
As Nitish Phanse said, it is because the page is cached. Turning off browser caching will solve it.
I faced a similar problem, when any of the changes in CSS were not being reflected in the webpage, because the cached version was being used by chrome. However, the changes were visible in other browsers and devices. Turning off caching in chrome solved this problem for me.
I prefer to use incognito mode when developing website because when browsing normally the files are cached, thus, not reflecting the changes you made. When you use incognito mode, fresh cache and cookies are stored and the cache and cookies are disposed when you close the incognito window. Another plus point of using incognito mode for testing is that, it disables all the plugins, unless you explicitly enable them.
You might want to check out this question on Quora for further details on why to use incognito mode when developing websites.
Seems like you use quite amount of Chrome plugins. In Incognito-mode those are disabled by default. Try remove/disable AdBlock etc. stuff which blocks scripts and disallow them from running.
Makes quite a lot sense why they run in other browsers too.
I strongly recommend to NOT use plugins when you do web development. You might see different kind of behaviour with same code as user who do not use them. Only use this approach if you especially wan't to develop under certain conditions.
As most people suggest, it definitely sounds like a caching issue. Incognito doesn't load the page with cache. You could ctrl+f5 the page (reload without chache) and see if it still does it. If the caching itself proves to be an issue, you could add a ghost/phantom string (I don't know if that's the actual correct terminology). Basically you add,
<?php echo '?'.date('Y-m-d H:i:s'); ?>
at the end CSS or JavaScript import (whatever may cause the issue). I.e,
<script src="/js/regexps.js<?php echo '?'.date('Y-m-d H:i:s'); ?>" type="text/javascript"></script>
What this does, is that it will prevent people from caching your file, since the name of that file will change by the second. This way, you make sure that if you make changes to files that are often cached, that everyone gets the uncached changes as you update your CSS/JavaScript or whatever. This is very useful for files where you make JavaScript check for instance, in case you make changes to some regex etc.
Ok; I'm stumped on this one. This regards the built-in draggable sort functionality you use for basic blocks or organizing books. I'm using the latest Firefox on Fedora 20. I also use profiles, meaning different instances of Firefox with separate caches and add-ons. However, in both profiles, I am logging into my Drupal site with the same credentials.
The Problem: For the last few days my primary browser has suddenly stopped showing the draggable handles in any primary Firefox profile. Inspection of the code shows that they are receiving a "display: none" element style in every case. However, this is happening only in one of my Firefox profiles. If I could even duplicate the problem in my other profile I'd have some clues, but I can't get them to disappear there any more than I can get them to come back in my primary. Remember, I'm logged into my Drupal site as the same user in either case, so it shouldn't be a permissions thing.
Things I've tried so far:
disabling all add-ons
Clearing all memory and caches. Again, and again, in conjunction with everything else I've tried
Clearing all Drupal caches
Force-refreshing the pages (shift+r)
You can see the problem here; it's not even a stylesheet thing, but something effecting generation of the drag-handle elements to apply a "display:none" to them.
See my firebug comparison screens attached.
EDIT I "cloned" my profile by creating a new Firefox profile and syncing everything (addons, history, etc); the new profile does NOT have the problem.
After clearing my cookies (a separate operation from all the cache clearing), it was fixed. I am still perplexed by why there should be a cookie with the power to toggle draggable blocks, but there we have it.
Solution: Clear Cookies
As brilliant as Firebug is, I would consider switching my JavaScript debugging to Chrome if I could figure out how to get it to always re-download styles and images on every visit to the page?
When I'm testing a page in Firefox, it always gets the latest version.
But in Chrome I often end up scratching my head over something that turns out to be a simple issue of the browser caching some earlier styles or images.
Is there a way to configure Chrome to cache less while you're developing?
I often use private browsing mode for this - it prevents caching of the stylesheets or scripts.
EDIT:
Another really easy way to do this in Chrome now is to go into the Chrome Developer Tools, click the settings gear (bottom right), and then check "Disable cache." See https://stackoverflow.com/a/7000899/4570.
A bit late to the party, but just for people who may pick up this page on a search, new versions of Chrome have a developers tools setting to disable the cache. Show developer tools (spanner->tools->developer tools) and on the bottom right is a tiny little gear. click that and a few settings appear in the developer tools window, one of which is to disable the browser cache. If you can't see it you may have to upgrade to a newer version of chrome.
Ian
According to Chrome help pages, Ctrl+F5, Shift+F5, Ctrl+R and Shift+R should force refresh. I haven't had problems with javascript and css but refreshing frames is another story. The caching can also be on your web server. The server can obviously be configured to cache css and javascript files.
Your best bet is to clear the cache between each load. With the latest version of Chrome, the hotkey is the same as firefox (on Mac, it's Shift-Command-Del). However, they haven't focused the "Clear Browsing Data" button, so you have to use your mouse to click that button -- which is a total PIA when compared to Firefox (Shift-Command-Del + Return), or Safari (Option-Command-E + Return).
the 2.5 ways i do it are not "automatic" but they're very quick, and i don't have to remember to switch back from private browsing -
a) install Mouse Gestures and use (this is a great extension anyways, but even more so now that I know about) Up, Down, Up - this is a cacheless reload. You can get it here
b) ctrl+shift+r is [supposed to be] a cacheless reload. Even the help pages admit this isn't perfect
c) the .5 is a kind of a hack - but if you are working with CSS files, open a new tab and type in the address to the CSS file itself - you can see what changes are there, as well as make sure that you've gotten the latest one by refreshing this file before your other file. a bit of a pain, i know, but always works.
Not sure about your system but on this WinXP machine holding SHIFT while clicking refresh always forces a complete download.
That's what I do when doing CSS and image tweaks.
That Chrome needs to have must-revalidate in the Cache-Control` header in order to re-check files to see if they need to be re-fetched the way that the other browsers do by default.
Recommend the following response header:
Cache-Control: must-validate
This tells Chrome to check with the server, and see if there is a newer file. IF there is a newer file, it will receive it in the response. If not, it will receive a 304 response, and the assurance that the one in the cache is up to date.
If you do NOT set this header, then in the absence of any other setting that invalidates the file, Chrome will never check with the server to see if there is a newer version.
Here is a blog post that discusses the issue further.