Questions tagged [expires-header]

a HTTP Response Entity Header Field that specifies the date and time after which a response should be considered stale

The Expires HTTP Response Entity Header Field specifies the date and time after which a response should be considered stale. The Expires value must be a date in HTTP-date format.

Example

Expires: Sun, 06 Nov 1994 08:49:37 GMT

Resources

Related Tages

116 questions
1
vote
0 answers

Why do Firefox and Chrome react differently to these HTTP headers?

I'm not sure if my question is based on a lack of understanding - or on Google Chrome working incorrect. My server sends the following HTTP headers (see yourself): Etag:"1031384541" Expires:Mon, 03 Nov 2014 00:01:46 GMT On a reload Firefox will NOT…
Eddie
  • 109
  • 1
  • 11
1
vote
2 answers

Negative Specific FilesMatch in Apache2

I want to set expiry date for all file except the 2-3 files how to use negative filematch in apache2
Okky
  • 10,338
  • 15
  • 75
  • 122
1
vote
1 answer

MediaWiki sends wrong header expires

I have Debian, Apache, MediaWiki. I set Expires in .htaccess for plus one month. MediaWiki sends header Expires: Thu, 01 Jan 1970 00:00:00 GMT. But if I create any simple script or file, it shows the correct information. Anyone else encountered…
1
vote
1 answer

ExpiresByType text/x-javascript and google analytics

Before implementing Google Analytics on my site with the latest javaScript code directly after the body tag, I had and still have this code in my .htaccess: ExpiresByType text/x-javascript "access plus 1 month" Does this mean that every user that…
Robin Cox
  • 1,470
  • 2
  • 16
  • 31
1
vote
0 answers

How to change status as "active" or "Expire" based on time

I want to change status as active or Expire based on time please help me build my code. I am attaching my build code.
1
vote
2 answers

Is there any way to set expiry headers in asp.net without making changes in IIS 6 Configuration Manager

I Need To Set Expiry Headers In my Asp.net code.. Is there any way through which I Can Add expiry Headers through code.? I Have tried adding the following code in my asp page <% System.Web.HttpContext.Current.Response.AddHeader(…
Crazy Programmer
  • 196
  • 1
  • 3
  • 18
1
vote
0 answers

How do I get element images to be cached in Blackberry 10 Webworks app?

Is there some configuration setting I need to use to get Webworks (on BB10) to cache images served from a server? I have a BB10 Webworks application that dynamically adds and remove html from the DOM. Images referenced in elements load as…
1
vote
1 answer

Set expires to max for all images of all servers in nginx

I have an nginx setup with multiple server blocks. I'd like to know if there's a way to globally set the value of expires to max for all images, CSS and JS across the server. I know I can use this: location ~* \.(jpg|jpeg|png|gif|ico|css|js)$ { …
user1544337
1
vote
0 answers

Why to specify Last-Modified?

I'm bit confused with this header. I already added "Expires" and "Cache-Control: max-age" in my .httaccess. I also removed "E-tag" and "Last-Modified" as per advice: If you remove the Last-Modified and ETag header, you will totally eliminate…
Solver
  • 169
  • 7
  • 23
1
vote
1 answer

Adding Expires headers to favicon.ico using Nginx as proxy of node.js

My site is running on node.js and I'm using Nginx to server my static files from a cookieless domain. For these files I have setup Nginx to set the expires headers. However it does not seem to be working for my favicon. My Nginx default config…
DivZero
  • 2,438
  • 2
  • 24
  • 23
1
vote
1 answer

expires header not working drupal

I am setting expires header in .htaccess file as below ExpiresActive On ExpiresDefault A1209600 It works for all the files that are in document root, but I have a separate mounted drive which is used as drupal file system ( private ), where I…
msmani
  • 730
  • 1
  • 7
  • 24
1
vote
1 answer

ASP.NET MVC ySlow Add Expires Headers for dynamically served script

I am serving Javascript vai a controller method that looks like this: [OutputCache(Duration = 120)] [Compress] public ActionResult JavascriptFile(String scriptName) { string content; if (HttpContext.IsDebuggingEnabled) { …
Aran Mulholland
  • 23,555
  • 29
  • 141
  • 228
1
vote
1 answer

Setting expire headers for a specific file or image

I have a website which extensively uses files which are static like Jquery library, images and some other functionality JS files. So, I wish to set infinite expiry time for those resources so that those can be easily retrieved from users cache. This…
Prashant Singh
  • 3,725
  • 12
  • 62
  • 106
0
votes
0 answers

How to improve speed on a Razor page with expire headers and Gzip compression?

When testing my website on tools.pingdom.com I get a warning that I should compress components with Gzip and also that I should add expires headers. I have set Common headers in IIS to 7 days, but this does not seem to help. Is there a programmatic…
Bjørn Hellesylt
  • 805
  • 2
  • 7
  • 10
0
votes
0 answers

Any way to tell browsers to fetch a fresh HTML page even if the cache said not to?

A couple of months back, I tested out the Wordpress automatic optimization feature in Cloudflare and started to get complaints from readers that our home page was no longer updating. I think the issue may have happened because I had my Cloudflare…