2016-03-16 51 views
0

我在一個wordpress網站工作,我看到一個css文件大約需要10秒加載,並延遲了頁面顯示,所以我想知道如何使這個加載速度更快。CSS加載延遲頁面顯示

我已經安裝了緩存插件,並使用visual composer插件。 視覺作曲家的CSS文件造成延遲。

標題是這樣的:

<html lang="en-US" prefix="og: http://ogp.me/ns#"> 
    <head> 
     <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> 
     <meta http-equiv="X-UA-Compatible" content="IE=edge"> 
     ... 
     <link rel='stylesheet' id='vc_plugin_themes_css-css' href='http://www.example.com/wp-content/plugins/easy-tables-vc/assets/css/themes.css?ver=4.4' type='text/css' media='all' /> 
     <link rel='stylesheet' id='js_composer_front-css' href='http://www.example.com/wp-content/plugins/js_composer/assets/css/js_composer.css?ver=4.7.4' type='text/css' media='all' /> 
     <link rel='stylesheet' id='ubermenu-css' href='http://www.example.com/wp-content/plugins/ubermenu/pro/assets/css/ubermenu.min.css?ver=3.2.0.2' type='text/css' media='all' /> 
     ... 
     <script type='text/javascript' src='http://www.example.com/wp-includes/js/jquery/jquery.js?ver=1.11.3'></script> 
    </head> 

你認爲我應該在頁腳移動js_composer.css?或者有什麼我可以做的嗎?

問候

+1

您將JS移動到頁面的結尾處,而不是CSS。我可以看到它是[大文件](https://vc.wpbakery.com/wp-content/plugins/js_composer/assets/css/js_composer.min.css?ver=4.11)。雖然我不認爲這是你面臨的問題。你有什麼樣的事情來改善網站的交付和資產?這裏有一些[優化技巧](https://developers.google.com/speed/docs/insights/rules#speed-rules)。 – hungerstar

+0

這不是在WordPress中加載css和js的最佳方式:請參閱http://code.tutsplus.com/tutorials/loading-css-into-wordpress-the-right-way--cms-20402 – meck373

回答

0

使用網站如gtmetrix.com,會告訴你這個問題具體是什麼,什麼可以做,以解決這個問題。他們非常豐富和分析。您可能需要暗示服務器更改或管理員頁面的更改,但它們完全可行。