I just ran into a problem, While I was updating the js and css files for my website on a server, I do not see the immediate change. However, if I were to edit these files on a local computer or go on incognito mode on chrome, I see the change right away.
let's say I have:
div{width:100px}
after I change it to div{width:200px}, when I pop open the developer tool, it still reads div{width:100px}.
I feel like I need to clear something for the broswer, any explanation for this?
Check the caching headers you are using for static resources. The browser is likely using a cached version.
Related
Why when changing the CSS in the dev tools only temporarily have effects and not after the page is reloaded.
Short answer: you have modified just a local copy. To learn how your browser works: Inside look at modern web browser
When you edit the website in developer console or inspect elements it will be saved until you reload the page
I want to add a button to my visual C++ form that will open with a specific browser. So far for links I've been using:
System::Diagnostics::Process::Start("UrlHere")
Which, as standard, opens with whatever your default browser is.
I'm wondering what the process would be to force the URL to open with a specific browser and if it's possible without the use of ShellExecute?
Edit - You are correct, this is C++/CLI. Removed the C++ Tag.
Edit Edit - Apologies if it came across as misleading. Some slight elaboration;
The buttons will launch to application URL's, some of which can only be used in Internet Explorer, others that CAN (and should) be used in Chrome. This is why I need to avoid using the default browser and have different buttons using different browsers when launching URLs
Before answering the 'how', I'd like to ask the question "should you be implementing this?"
By not launching the user's default browser, you are subverting the user's decision.
Perhaps the user prefers a particular interface, and is willing to live with the incorrect renderings that come with it.
Perhaps the user has a browser addon that they really need, such as a screen reader for the blind.
You are requiring additional software installed that the user may or may not want.
Perhaps the user doesn't want Chrome. Perhaps the user prefers FireFox.
You are saying that you know which browser is best, now and forever.
What if the next version of IE makes it work with the sites that are currently Chrome-only? What if the next version of Chrome fixes the sites that are currently IE-only?
What if the site changes so that it works in more browsers?
Do you go back and release a new version of your software that changes the browser for particular sites?
You're trying to solve a problem that may already be fixed.
Both Chrome and Firefox support a addon that will render a tab using the IE engine. It can be set to automatically activate when certain URLs are seen.
Perhaps there is a browser that already works with all your sites, that you don't know about.
Therefore, my recommendation is no, do not do this. The user has decided which browser they want to use, respect that decision and use the default browser.
That said, here's how you would do it: You could use the CreateProcess method, but you're in managed-land, so you might as well use it. Use the Process class to launch the new process for you.
Process^ browserProcess = gcnew Process();
browserProcess->StartInfo->UseShellExecute = false;
browserProcess->StartInfo->FileName = "C:\\Program Files (x86)\\Internet Explorer\\iexplore.exe";
browserProcess->StartInfo->Arguments = "http://www.google.com";
browserProcess->Start();
I have tried using the Tincr Chrome Extension now on Windows and Linux (Ubuntu) and it still does not seem to do the Live Reloading it claims to on its website when I am editing the file in an external editor. The Tin.cr website claims:
Any CSS or JavaScript changes you make in any editor reloads in Chrome
without refreshing the whole page
To explain further, I have tried installing this extension as an unpacked extension in Chrome with Developer Mode checked under chrome://chrome/extensions/ as suggested in the Tincr documentation. I have also tried installing this extension directly through the Chrome Web Store. The effect has been the same.
In terms of setting up Tincr, I have tried opening up my file locally without a web server using file://C:/htdocs/file.html which Tincr claims in its documentation it can read automatically without needing any setup, and also I have tried opening up my file via an Apache Web Server on localhost e.g. localhost/file.html and setting up the Project Type in Tincr as Http Web Server as suggested in the documentation, but both ways have been to no avail.
In terms of editing my local file, I have used a number of different external editors, for example, Geany on Ubuntu and Titanium Studio on Windows.
After editing the file in the editor I have left the page I am editing open in my Chrome browser with the Tincr plugin setup and enabled. However, after saving my file in the editor and looking to see if it live reloads in Chrome, nothing happens. The file simply stays the same. Again, to reiterate, this is happening in both Windows and Linux (Ubuntu).
And so my question is this: has anyone successful tried using this extension with an external editor and if so could you please detail the steps to get live reload to work as I'm beginning to think this may be a bug in the extension?
I think I may have an explaination. Having a look at the google groups for Tincr, it appears Tincr does not support html file refresh, and that it can only detect changes in either css or javascript.
source: https://groups.google.com/forum/#!topic/tincr-for-chrome-devtools/VyC0mavLs_A
I have a HTML file, which I've uploaded as a web resource and linked to via an activity's form designer in an IFRAME. So far, so good.
Then, when I edited the source file locally and uploaded it (browse-save-publish, of course), I got no difference in the appearance on the screen. Here's the weird part. When I open the uploaded file in the editor, I can see the changes to my source code. On the RTF tab I can also see the change in colors of the background.
However, reloading the "create new"-form doesn't bring those changes to the client! I've tried restarting the window, restarting IE, clearing the cache. Nothing helps.
When I entered the very same page from a different client, I got to see the updated version. But after that, the subsequent changes are not updated either. It's like if IE thinks "oh, matey, ya wanna cache that for life, I see". Well, I don't. I'd like to see my edition in action pretty much directly and without creating a new account with a new client. :)
After a while, the update seems to go through and I get to see a new version but not in all browsers.
What is causing it?! How do I kill it?
(Win8/IE10/CRM11OL)
I have seen CRM do some weird IIS Caching. I'd assume this is a server side issue, but your using crm online, they won't let you run an IIS reset now will they? :) Have you tried running it on a new client in private browsing mode, deploying your change, and opening a new private browser to test if it is a client caching issue or a server caching issue?
I'm having a very bizarre issue. I have been building a website locally on my linux box and all was well until I uploaded the site files to a place where i have some hosted space. Everything renders exactly the same except one element in my footer which i think is affecting some jquery animation i am using. I thought maybe I was missing files or hadn't uploaded the latest versions of everything, so I deleted the server directory and re-uploaded everything exactly as is from my local copy. And yet, the problem remains. I'm not sure how this is happening. Has anyone seen this before, or does anyone have an idea what could cause this? I'm baffled! Thanks everyone!!! I am attaching screen shots.
Seems to be a cache problem. Try to force a refresh with F5 or CTRL+F5.
Try clear your cache in your browser settings.
If that don't work, use Firebug (an Firefox browser addon) to check actual css at your footer. This will show the problem.
BTW: don't use spaces in your URL if you can. Don't use spaces in your filenames/folders.