I'm doing some front end work and I need to test how the program reacts when it loses a network connection. Firefox has a "Work offline" setting but that drops the connection for every tab -- I only want to disable the network connection for a single tab. Chrome has this with an "Offline" checkbox in the Network tab of the devtools that makes this really convenient.
This is what this feature looks like in Chrome:
The best solution I've found is to use "Request Blocking". Add * to match all requests. It also blocks local requests.
~~As of at most v97, work offline can be found by clicking File > Work Offline in the top left of the window. If you do not have the File menu, try pressing alt to make it appear.
As commentators note, this apparently allows requests to localhost, and will set all of your tabs to offline mode.~~
Greg has a much better answer
Yes we do have the option in firefox
version: 65.01
Click on the setting button(hamburger)
Then click the web developer option
Then click on the work offline option
For at least Firefox v92 (and probably previous ones) offline mode can be found by pressing ALT to bring up the File/Edit/View etc menus, then File > Work Offline.
Related
Like in the title, how to clear that cache?
There are some plugins, but its installation is disabled for Firefox Quantum...
https://addons.mozilla.org/en-US/firefox/addon/dns-flusher/
https://addons.mozilla.org/en-us/firefox/addon/clear-dns-cache/
You can take look at about:networking#dns which directly lets you clear the cache.
And Where does Firefox keep cached DNS responses? had already been answered by Firefox's Support Team.
ScreenShot:
By the way for chrome it is chrome://net-internals/#dns
Open Preferences by typing about:preferences in address bar
Goto Privacy & Security in the menu on the left side
In the History Section click at the link clear your recent history and select:
Time range to clear: Today (or whatever fits)
Under details select Cache
Submit form with Clear now
This worked for me and is the same as the other answer which was down-voted by any reason, maybe people didn't actually try or maybe something else was missing. Not sure if also the DNS cache of the OS needs to be cleared:
On macOS I typed in command line: sudo killall -HUP mDNSResponder;say DNS cache has been flushed
On Windows it should be Start > Type: cmd > run: ipconfig /flushdns
Restart browser to flush DNS cache.
DNS cache is not stored on disk.
Or type: about:networking (see great answer by Shakiba Moshiri)
The new extension framework used by Firefox Quantum doesn't allow functionality like provided by these extensions. That is why they are not being updated to work with Firefox Quantum.
So the way to actually clear the cache is as follows
Go to the History menu
Select Clear Recent History
Check all boxes
Under Time range to clear select Everything (except passwords, if desired)
Click Clear Now.
I'm having trouble downloading files from my client's development server.
They said that one of their connections is working just fine with the exact same FTP credentials.
To help resolve the problem they asked me to give them "Toggle Transcripts"
What are toggle transcripts and how can I get them from CyberDuck?
In my version, I have a "Toggle Log Drawer" menu option (under the View menu, I think). Selecting this reveals an extra window element, where information about the FTP session is printed. In your case, this window may contain information that your client can use to diagnose the problem. It's just a log of your activity when using Cyberduck.
I'm currently working on a project where I have firefox launching in one of three modes:
normal
full - kiosk mode with only tabs, and home back and forward navigation showing.
Super - kiosk mode no tabs or anything showing just the content window (true kiosk mode)
Now due to time constraints I have implemented via pygtk rather than creating a custom Firefox extension as the requirements of the project would require a new flag adding to the command line in order to identify what mode it was to launch in. The approach I have used works beautifully, Great. . .
However the problem now is how can I disable all of the hot keys i.e. Ctrl + T, etc, without writing a extension. I am unable to use an existing extension because I need the shortcuts available when firefox is in normal mode and as firefox (for the project) can only be started via the command line programatically I would need a flag to determine weather to restrict the hot keys or not.
I was hoping to be able to achieve this using user.js which is placed programatically into the correct profiles when they are created in another bit of my application. I have tried using user.js by modifying accelKey, chromeAccess, contentAccess, generalAccessKey and menuAccessKey and setting their values to 0, which works for menu access but not for anything else.
Finally the Question
Is it possible to disable all shortcuts from user.js or can you only do it through an extension?
No, you cannot disable shortcut keys via preferences. Not all shortcut keys use the configurable Accel modifier, but even the ones that do cannot be disabled via preferences. In case you are interested, the code handling them only recognizes Meta, Alt and Ctrl as valid values, with Ctrl being the default for inputs that aren't recognized. You can try using Meta (the corresponding code is 224), it seems unmapped on PC keyboard. For anything more fancy than that you will need an extension.
I apologize if this sounds like an ad instead of an answer, it's not meant to.
If you do have time constraints and you just want to get a hold of the code you need, there is an open source kiosk project called Webconverger that has already done a lot of the heavy lifting.
Chrome caches DNS records and tends to ignore changes to the hosts file after it has successfully connected to my site (barring a restart). With DNS pre-fetching enabled, it is even more pronounced.
Are there any page headers that will instruct Chrome not to cache a site's DNS? Like Cache-Control or a response status like 307 Temporary Redirect?
I'm not sure if this is exactly what you're looking for, but this annoys me too switching dev environments, and I stumbled across this internal chrome page that lets you clear the cache by the click of a button:
chrome://net-internals/#dns. After going there click the Clear host cache button.
Edit
As noted in an answer below, the reason this doesn't immediately take effect is that you also need to flush the open sockets. After clearing DNS cache, also go to: chrome://net-internals/#sockets and click on the Flush socket pools buttons.
Also keep in mind the operating system might do its own level of caching. Linux doesn't cache dns entries I think (at least for me clearing the chrome cache is good enough), but for windows or mac you might need to flush the OS-level DNS cache as well. Run ipconfig /flushdns from command line for windows or sudo dscacheutil -flushcache from command line for mac.
This is probably a real bug in Google Chrome. I created http://crbug.com/65570 to track it, but please add any additional information you can think of to the bug so we're sure we understand your problem correctly.
It sounds as though the only work-around besides closing Chrome is unplugging the network cable and then plugging it back in. When Chrome sees such an event, it drops its socket and dns cache. The correct solution for the bug is likely to do the same when we see /etc/hosts has changed.
If you'd like to know when the bug is fixed, go to http://crbug.com/65570 and click the star next to the bug number. And, like I said, please add any additional information you can to the bug.
In my case I often switch from my dev web server and a production server using custom hosts files, in order to clear all the dns cached info from chrome I use this procedure, and it works instantly in the same tab where I need to load the updated web site address:
Copy and paste this url in chrome: chrome://net-internals/#dns
Click on the "Clear Host Cache" button and also click on the small black arrow in the top right corner of the window, click "Clear cache" and "Flusk Sockets", and the new address will be loaded istantly.
How can I make the tootip/flyover of the tabs appear faster? There is too much reaction time, it takes ages to look through many of them.
I have most of the time 100 tabs open in Firefox (I am using the tab mix plus addon - "tmp").
To see what's in the different browser windows I do not activate them, but I just move the mouse over the tabs.
After some milliseconds a tooltip/flyover appears (a little box at the mouse pointer is drawn above everything below) and it contains information from the header of the web page that belongs to the tab. But there is a pause of some milliseconds before they are shown.
If there is not a specific about:config variable I would also be interested how to change firefox code (as I assume this is not built into tmp, I didn't find it in the options)
I do not use the tmp feature "select tab by pointing after xxx ms", which could probably interfere.
Thank You
Karl
It may not really be a system wide problem as some others are claiming. For my website, I noticed that tooltip delay in Firefox was much higher than in Chrome. So I researched a bit, and fortunately it's easy to fix.
Just open your about:config in Firefox, and right click, New->Integer value. Give this name to the preference:
ui.tooltipDelay
Give it the value you like, I've just set that to 100 and it works nice now (Their default value is 500).
Source: https://developer.mozilla.org/en-US/docs/Mozilla/Preferences/Preference_reference/ui.tooltipDelay
The tooltip delay variable isn't in Firefox's about:config because it is a system-wide variable.
If you are using OS X you can change it using these commands in terminal:
// make the change global (applies to all apps)
defaults write -g NSInitialToolTipDelay -int 500
// just for firefox
defaults write org.mozilla.firefox NSInitialToolTipDelay -int 500
I don't know how this can be done under windows. (maybe a registry key or something
EDIT: I just found this / wikipedia. Maybe you can give it a try?
I believe that Tweak UI from Microsoft PowerToys has a setting to change this on Windows. Look for the download on the right of the page about halfway down.