Desactivating a setinterval function? - console

I have absolutely no idea why, but on 2 websites (2 websites that I professionnaly work on, and they havent been hacked or compromised), my Chrome console keeps clearing every 500ms.
Which is pretty annoying.
I desactivated all extensions. Tried private browsing. It's the same thing.
I uninstalled chrome as well as my extensions. Same.
When I try to reproduce it on someone else's computer, I cannot.
When I use another Chrome session the issue does not happen.
I have absolutely no idea how to get rid of this or what is the exact cause of the issue.
The code running is :
setInterval(function(){console.clear();console.info('Console was cleared by browser extension.');},500);
Since I unfortunately do not seem to find the reason, my only question will be : would there be a way to desactivate that code or postpone the setinveral to a bigger number?
Thanks !

In Chrome, on the developer tools, click on the settings icon, and tick the the "Preserve Log" option so the console is not cleared.
If your websites happen to be ecommerce (Magento specially) I'll advice you to check your code well for unknown js. This is one of the "symptoms" of the Magecart credit card skimmer. Preserve log option

Related

How to debug "Aw, Snap!" Chrome (when opening multiple tabs)

If I ctrl-click a link in my app and open ~10 tabs, for 2-3 of them I get the
I have no idea where to start investigating this 🤷
I am working on ASP.NET (.NET6) MVC + Knockout, dunno if this is relevant.
Looks like a memory leak of some sort, that Chrome can't handle.
Chrome Error code: STATUS_BREAKPOINT
Edge (also based on chromium) Error code: STATUS_ACCESS_VIOLATION
Try making sure Chrome has all the permissions, also make sure you singed in before you started using it. If this doesn't work. Unistall it and install it again. If you have the same problem. Debug it with Python/Pycharm. Hope it helps.

Chrome downloads aspx instead of render, IE works

Whenever I try visiting an aspx file in Chrome, the browser will download the file. When I open it in IE, it will actually render that page. I'm not sure what changed with Chrome as this was working, then half way through the day decided to stop working.
I've tried following aspnet_regiis -i with no success. Other aspx pages render without issue. I've been poking around IIS trying to find something that might indicate an incorrect setting, but cannot find anything in particular.
I've done plenty of Googling without any helpful results.
I'm not sure what other information to provide at this time, so please let me know if I can provide any specific information to help.

Chrome Developer Console Started Logging Too Much Info. CSS Warnings

I do a large part of my development work in the Chrome developer console, and love it, but recently something highly annoying has happened.
Every page load, I now get a log of every CSS property warning, a considerable list that fills the entire console with warnings. I know I can set the log level to filter out warnings, but I want to see some warnings, particularly script related. Also, this resets itself every page load, so all the CSS warnings fill up my console, and look visually upsetting.
See the screenshot:
I believe that this started happening immediately following the most recent chrome update, but I was also fooling around with some of the settings in the console. I've looked through the settings in the console and under chrome://flags but haven't found anything. Does anyone know why this is?
I've never had this happen to me, but have you tried deleting the history?
https://developers.google.com/chrome-developer-tools/docs/shortcuts#console

I don't want to display back and forward button in my browser. Is there any solution apart from popup trick?

customers does not want to allow user to use back or forward button. Just a clean page without commandbar and toolbar, same for FF an IE.
Disabling them is not an option as now.
You cannot change that kind of thing in a existing window -- the only way you can make those disappear is by opening a popup, specifying they should not appear in that popup when it's being opened.
Still, note that you should not try to disable those buttons nor have them disappear : your application should work fine with them, handle their actions -- after all, it's one of the few things users have understood in browsers...
And as a user, this is disturbing and annoying :
I don't like popup windows -- and I'm not the only one who doesn't
I don't like when a website tryies to take control over my browser
It will not always work anyway.
And, as a sidenote : even if the back/forward buttons are not displayed, users can still use Ctrl+left/right or some kind of equivalent !
I know this is not easy, but a part of your work as a web-developper is to explain your clients how Internet and web-applications work... not the same way as desktop applications !
If you can force your users into IE (can't believe I'm suggesting use of IE!) you can do this trick. Try running this from the command line
"C:\Program Files\Internet Explorer\iexplore.exe" -k
This will force IE into kiosk (or full screen mode), similar to pressing F11 when in a usual browser session.
PS. I agree with the other answers suggesting this should be discouraged but there are instances (such as when the end user really can't be trusted) that this is a good solution.
No, there's no other way.
However, this is extremely annoying behavior and should be greatly discouraged. This isn't a code issue to solve...this is behavior that shouldn't be implemented at all.
My opinion here, you have a client problem not a code problem. Whatever standard is the expectation, and the user has the expectation of having their back/forward buttons, break that and you break their experience.
Ever see a Windows application that removes the taskbar? That's the equivalent...
I don't think there is a reasonable way to disable the behavior. You may get rid of the buttons in various ways, but the behavior is still there (through keyboard commands, popup menus and so on).
The only reasonable way is to make your web application follow web semantics, and make the client realize this.
many web based ERP (for example) does not tolerate people using navigation buttons. BUT these web applications handle the fact people use these buttons and do not crash. That's what you should do. If each time people use the back button, they get an error message, they will quickly stop using it.
The solution that used to work in IE was adding a startup script with one line:
location.forward();

Does this seem like an IE8 float bug to you?

I've noticed a strange behavior in two different sites when using IE8.
The first site is in the site that I maintain xebra.com.
The second site is google analytics.
The behavior is that when an address is typed directly into the address bar of IE8, both sites display correctly,
But when one of the sites has already been loaded, and you press the refresh button or F5 key, the layout gets all screwed up:
See screenshots here: here
Something is causing IE8 to render in 'quirks mode' which causes the breakage.
You can duplicate this by browsing to your site in IE8 and selecting Tools > Developer Tools > Document Mode > Quirks Mode.
Make sure your document is always being served in standards mode.
EDIT My original answer had 'compatability mode' where it should have read 'quirks mode' - the two are different.
JS.Companion was what was causing this odd bug, and not IE8. Phew!
http://www.my-debugbar.com/wiki/CompanionJS/HomePage
I spent the whole morning trying to figure out what was going on, I removed companion.js and bingo my site is perfect! thanks for this.
That's really strange. I don't have the problem on my computer with Companion.JS installed and http://www.xebra.com/ web page (under Vista SP1).
I would be happyto correct the Companion.JS bug that generates this problem if you can provide more information about the problem.

Resources