웹 서버가 압축 된 컨텐츠를 제공하고 있으며 장래에 헤더가 만료되는지 여부를 어떻게 확인할 수 있습니까?아파치가 "압축"및 "먼 미래"만료 날짜를 사용하고 있는지 어떻게 확인합니까?
<IfModule mod_deflate.c>
AddOutputFilterByType DEFLATE text/html text/plain text/xml
BrowserMatch ^Mozilla/4 gzip-only-text/html
BrowserMatch ^Mozilla/4\.0[678] no-gzip
BrowserMatch \bMSIE !no-gzip !gzip-only-text/html
</IfModule>
<IfModule mod_expires.c>
ExpiresActive On
ExpiresDefault A0
ExpiresByType image/gif A2592000
ExpiresByType image/png A2592000
ExpiresByType image/jpg A2592000
ExpiresByType image/jpeg A2592000
ExpiresByType image/ico A2592000
ExpiresByType image/x-icon A2592000
ExpiresByType text/css A2592000
ExpiresByType text/javascript A2592000
</IfModule>
Picture.png http://img535.imageshack.us/img535/5110/picturemt.png
: YSlow에 여전히 내가 일반 텍스트 및없이 전송되는 자원이 내게 말하고있다 "먼 미래"나는 .htaccess
파일에 다음 항목을 추가 한 경우에도 헤더를 만료 그것이 말하는 것들 중 하나는 헤더가의 favicon.ico 파일 만료 필요하며, 여기 방화범에 나와있는 헤더가 있습니다 : 그것은 gzip으로 압축 할 필요가 기본 색인 말한다 자원의
HTTP/1.1 200 OK
Date: Sun, 18 Sep 2011 00:50:03 GMT
Server: Apache
Last-Modified: Tue, 21 Dec 2010 21:47:19 GMT
Etag: "f8233-47e-497f294aba7c0"
Accept-Ranges: bytes
Content-Length: 1150
Cache-Control: max-age=0
Expires: Sun, 18 Sep 2011 00:50:03 GMT
Keep-Alive: timeout=5, max=100
Connection: Keep-Alive
Content-Type: image/x-icon
하나. PHP 파일, AFAIK의 헤더를 전송하지 않습니다. 나는 이것이 아파치 2 서버이기 때문에 mod_deflate
를 사용하기 위해 노력하고있어
HTTP/1.1 200 OK
Date: Sun, 18 Sep 2011 00:49:33 GMT
Server: Apache
X-Powered-By: PHP/5.3.6
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Set-Cookie: PHPSESSID=754163feea6fab8a8d6d7f0ef6ed3c29; path=/
Keep-Alive: timeout=5, max=100
Connection: Keep-Alive
Transfer-Encoding: chunked
Content-Type: text/html
다음은 응답 헤더입니다.
무엇이 잘못 되었나요? 내가 무엇을 확인할 수 있습니까? 어떻게 테스트 할 수 있습니까?
"ETag가 잘못 구성되어있는 17 가지 구성 요소가 있습니다"라고도 알려줍니다. 그 의미가 확실하지 않습니다. 전자 태그가 헤더에 있고 그들은 나에게 잘 보입니다.
YSlow는 일반적으로 매우 정확합니다. Firebug의 응답 헤더 또는 Chrome 개발자 도구의 네트워크 탭을 볼 수도 있습니다. –
예, 위의 헤더를 게시 한 방법입니다. 그러나 YSlow 보고서에 영향을 미치지 않았던 구성에서 변경된 것처럼 보였습니다. – cwd