2017-04-12 116 views
-1

我已经完全在PHP中开发了我的网站,现在当我测试我的网站的速度它slow.In谷歌网站速度测试“https://developers.google.com/speed/pagespeed/insights/?url=https%3A%2F%2Ftrainsrunningstatus.net%2F”这显示“利用浏览器缓存”。 请建议我如何提高我的速度。如何提高杠杆浏览器缓存

+0

我还需要提高我的网站的子页面 - [https://trainsrunningstatus.net/running-status](https://trainsrunningstatus.net/running-status) –

回答

0

除了这个htaccess代码,没有什么不同之处了。根据你的文件我的你自己的过期列表。

## EXPIRES CACHING ## 
<IfModule mod_expires.c> 
ExpiresActive On 
ExpiresByType image/jpg "access plus 1 hour" 
ExpiresByType image/jpeg "access plus 1 hour" 
ExpiresByType image/gif "access plus 1 hour" 
ExpiresByType image/png "access plus 1 hour" 
ExpiresByType text/css "access plus 1 hour" 
ExpiresByType text/html "access plus 1 hour" 
ExpiresByType text/x-javascript "access plus 1 hour" 
ExpiresByType image/x-icon "access plus 1 hour" 
ExpiresDefault "access plus 1 hour" 
</IfModule> 
## EXPIRES CACHING ##