Cevaplar
-
htaccess dosyana aşağıdaki kodu yapıştır farkı göreceksin.
<ifmodule mod_expires.c>
<filesmatch "\.(jpg|gif|png|css|js)$">
ExpiresActive on
ExpiresDefault "access plus 1 year"
</filesmatch>
</ifmodule>-
sharq
ben bunu # 1 YEAR
<filesMatch "\.(ico|pdf|flv)$">
Header set Cache-Control "max-age=29030400, public"
</filesMatch>
# 1 WEEK
<filesMatch "\.(jpg|jpeg|png|gif|swf)$">
Header set Cache-Control "max-age=604800, public"
</filesMatch>
# 2 DAYS
<filesMatch "\.(xml|txt|css|js)$">
Header set Cache-Control "max-age=172800, proxy-revalidate"
</filesMatch>
# 1 MIN
<filesMatch "\.(html|htm|php)$">
Header set Cache-Control "max-age=60, private, proxy-revalidate"
</filesMatch>
böle yptım ama bi deişiklik olmadı gine ön bellkleme ypmıyor .s11 yıl önce yazılmış -
sharq
bide bi yerden bunu duydum ve yptım ne işe yaradığını bilmiyorum .s
<?php header("Expires: Tue, 01 Jan 2000 00:00:00 GMT"); header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); header("Cache-Control: no-store, no-cache, must-revalidate, max-age=0"); header("Cache-Control: post-check=0, pre-check=0", false); header("Pragma: no-cache"); ?>
11 yıl önce yazılmış -
Kesali
Bu şekilde php dosyalarını cacheler. .htaccess dosyasından cachelersen uzantısını belirlediğin dosyalar cachelenir.11 yıl önce yazılmış
-