File default.css appears in browser after being deleted from server - file

I am making some changes to the css file for a website and I found out that my changes are disregarded.
In order to diagnose the problem, I deleted the only css file I have (default.css) from the server.
To my surprise, all web browers (Chrome, Firefox, IE11) are still capable of seeing and downloading the file. So, if I go to www.example.com/default.css, I can download the file despite the fact it is not there anymore! I used the command Ctrl + F5 to clear the local cash from browsers and reload the file default.css, but the file is still there and it contains the old version. I also used Ctrl + Shift + Del to clear everything in IE browser. Earlier today I created the file .htaccess to redirect example.com to www.example.com. I also use the services of cloudflare.
If I upload to the same location a different file, default2.css, I can view it correctly.
Any idea who delivers to me the old file? I suspect it may be cloudflare. I host my website on runhosting.com
Thanks,
Nick

Did you purge the file in CloudFlare?
CSS is a file CloudFlare caches & you would want to purge it if you make a change to static content we cache.

Related

if make i changes in cpanel filemanager it doesn't really take effects on the web site

so as you see from the address I make changes in the public_html folder and I see the changes through the cpanel filemanager. however, it doesn't make any changes in the website and when I try to see the files of the website through my domain Ienter image description here can see that there are no changes happened . the changes is like creating a new folder or file or even renaming a file
This type of problems may occur due to server sided caching or it can be a simple bug which doesn't let the code to execute it on the website.
Or might be the server issues, for which you should contact the customer care of your hosting provider.
Try to clean cache of your browser and also disable the caching in your server if enabled.
Try these all things and you may see changes.

Can I use "--allow-file-access-from-files" when starting chrome app?

I am trying to load a simple .txt file content with a Chrome App (using file: protocol); I need to show its content for the user in a <div>. I need to open the file from a path typed in a input text (or defined in a string variable).
The flag --allow-file-access-from-files works fine when I load my .txt file content through Chrome browser. However, when I try to do the same with my Chrome App launcher (I have applied --allow-file-access-from-files flag on it), it keeps telling
Cross origin requests are only supported for protocol schemes: http, data, chrome, chrome-extension, https, chrome-extension-resource.
I dont know if I am missing something or if it is impossible for chrome app.
My user will work with the app in Windows platform.
I finally figured out that --allow-file-access-from-files does not work at all in my case.
I started coding using fileSystem and made something like the recomended in this question, following the main example. Now I am able to work with files in a directory asking the user to choose it only one time.

Cakephp with Rackspace cloud database

I'm thinking about moving one of my clients mysql db to Rackspace could databases. Application is using Cakephp.. I would like to know if someone has experience doing so or will this work just by editing host/user/pass in the database.php file?
I havn't done so but Rackspace has a tutorial about doing so :
http://www.rackspace.com/knowledge_center/article/installing-cakephp-on-cloud-sites
It seems pretty simple, so you should not have any problems
Steps for cake
Locate the .htaccess file in the content directory. After "RewriteEngine on", add a new line with "RewriteBase /" to the .htaccess file and save the file back to the site. You will need to repeat this step for the rewrite rules in the .htaccess files in the app and app/webroot directories.
Load the site in your browser. You will notice several warnings concerning the installation. The first warning will be the following: Notice (1024): Please change the value of Security.salt in app/config/core.php to a salt value specific to your application [CORE/cake/libs/debugger.php, line 556].
Open app/config/core.php file and search for Security.salt. Change its value to whatever characters or string you would like, then save and close the file.
In the app/config/directory in FTP, rename the database.php.default file to be database.php.
Open app/config/database.php and scroll down to the bottom of the page to find the database connection information. Enter your database host name, user name, password and hostname, then save and close the file.
Reload your site in your browser.

What setting in IIS that could cause XAP to download everytime when access the page from fresh IE?

I have a sample program which does nothing but Hello World. I open IE and go to my development environement and access the silverlight, it loads the XAP first time and then if I close IE and open again, XAP does not get downloaded. Since there are no changes I expect it not to download.
After deploying it in QA environement, I open IE for the first time, it load XAP as expected. Now close IE and open again, I expect it not to download XAP but it does download XAP again. But if I would do refresh on the page it does not download XAp. So this happens only on Fresh IE open in our QA environment.
All the above tests are done on the same box with same IE setting. So there is no client side IE cache issue. I did check the date and Time on the servers to see if there is any difference as specified in silverlight XAP gets downloaded everytime
link and our servers are in same date and time.
Does any one know how to prevent IIS not to download everytime?
The default settings in IE mean that a fresh instance of IE will always attempt to fetch each unique URL when it is first encountered. IE does this even if the cache headers sent with the resource the last time it was fetched would indicate the resource is still fresh.
However IE will send If-Modified-Since and/or If-None-Match when it re-requests a resource that it has a copy of in its cache. Hence the server has the option of responding with 304 Not Modified, are you sure that is not happening? The 304 has no entity body and is therefore a cheap response.
Note also that IE can make some strange heuristic choices if the server fails to send any cache control headers with a resource. One of these choices is where the resource is quite large no caching is performed.
If you haven't already done so I would recommend you set some reasonable Expiration on the ClientBin folder in IIS Manager (in IIS7 select the ClientBin folder, select "HTTP Response Header", open "Set Common Headers..", enable Expire Web content.

How do I make my Apache 2 server force a browser to open a file transfer dialogue?

How do I make my Apache 2 server force a browser to open a file transfer dialogue if the URL points to a file with a .pln or .psa extension?
I have a simple LAMP server with CentOS 5, Apache 2, MySQL 5, PHP 5, recently built CentOS 5.2 i386 installation CDs. My web application generates files to be downloaded and imported into a custom application. The file extensions are .psa and .pln. How do I make my server force the browser to open a file transfer dialogue? If I point my browser to a .psa or .pln file on the Apache 2 server, the file's content is displayed in a pop-up window as simple text. I want a file transfer dialogue.
The web-app I am working on is deployed on another web-server and handles the .pln and .psa files as desired. I cannot compare server configuration files because I do not have administrator access to the working server.
How do I change my server's behavior? Does this require code changes to my web-app code (such as sending explicit headers)? If so, why does it work against the other server? Can code changes be avoided by configuring the server's default behavior?
You should be able to use the FilesMatch directive to add the necessary header.
<FilesMatch "\.(?i:pin)$">
Header set Content-Disposition attachment
</FilesMatch>
I tried several configuration changes which had no apparent effect.
I added the following line to my /etc/httpd/conf/httpd.conf file:
AddType application/octet-stream .pln .psa
I restarted the Apache server and it had no effect.
I added the following lines to my /etc/httpd/conf/httpd.conf file:
ForceType application/octet-stream
Header set Content-Disposition attachment
ForceType application/octet-stream
Header set Content-Disposition attachment
I restarted the Apache server and it had no effect.
If you have Firefox (and if not, why not?) install Chris Pedericks Developer Toolbar, and check that the headers are actually being set correctly. If so, it may be the fault of the browser. As I said, you can't be certain that any given browser will "correctly" interpret the response headers. What browser are we talking about here anyway?
If the headers aren't being set correctly, you may need to re-check your httpd.conf file. Possibly the directives you added aren't in the correct section? (e.g. under the wrong <Location > directive)
Forcing a browser to do something is always a tricky proposition, since the browser can ignore you and do what the hell it likes
That said, most browsers will prompt the user with a "save as" dialog box if the "Content-type" header is set to "application/octet-stream". Either write a simple wrapper CGI that serves up the requested file with the correct header, or fiddle with Apache2's mime-types (look in the config directory.)

Resources