ãªãã¥ã¼ã¢ã«ã«ã¦å°å ¥ãããCoreserverã§ããã°ã WordPressé«éåTips ï¼é¸ï¼
ã¨ããããããããã£ã¨ãªãã¥ã¼ã¢ã«ãããã®ã®ããããããéãã
ç»åæ°ãå¢ããã®ã¨ãè²ããªãã®ãæé©åãã¦ãªãããã ãã©ã
ãµã¼ãã¼ã®ã¬ã¹ãã³ã¹ãã¨ã¦ãé
ãã
ãã¡ãããµã¼ãã¼ã¯ã¯ã¼ãã³ã°ãã¢ã®å³æ¹ã Coreserver ã§ãã
ã§ããããããcoreserverã«æå¥è¨ããªããã ã£ã¦å®ãããã
ã¨ããããã§æ¬æ¥ã®ãã¼ãã¯ããªããã®ãã ããããããããã®æ¢ããã¸ã
ã¦ã§ãã®é«éåã¯å°å
å¦ã¨ä¸ç·ã ãï¼
ããããä½ã¯ãªãã¨ãã¾ãã¯å°å
ãç¥ãããã«ã試ãã«
Pingdom website speed test ã使ã£ã¦ã¹ãã¼ããã¹ãããããã
表示ã¾ã§ï¼ç§ããã¼ã¸ãµã¤ãºã¯850kBãããããã£ãã
ãããé
ããããããã®å°å
ã£ã¦ã°é
ãã£ãããããããªãã
ã¨ããããã§ããã¾ã¯ããã®ï¼âè¨ãæ¹ãå¤ãï¼é«éåã調ã¹ã¦
ããã£ã¨å°å
¥æ¹åèªåã¡ã¢ã
ãã£ãã·ã¥ãã©ã°ã¤ã³ï¼é£çºï¼
ã»Quick Cache â å
¨ä½çã«ã
ã»MO Cache â è¨èªãã¡ã¤ã«ç¨ã
ã»WP File Cache â PHPã®å¤æ°ç¨ã
ã»DB Cache Reloaded Fix â ãã¼ã¿ãã¼ã¹ç¨ï¼
諸åã®å£ã®ãã£ãã·ã¥ï¼é£çºï¼
å
·åãæªãã£ããåãä¸ããã¤ããã§ããã°ããã¯ãã¹ãéç¨ã§ãã
ãã£ã·ã¥ãã©ã°ã¤ã³ã§æå㪠W3 total cacheã¯ããããªã話ãã¡ãã»ãããã®ã§ãä»å㯠Quick cache ã使ã£ããã
åºæ¬çã«ã¯ãªã³ã«ããã ãã ãã©ãQuick cacheã¯ãè¨å®ç»é¢ã§ããã£ãã·ã¥ããããªãã¦ã¼ã¶ã¼ã¨ã¼ã¸ã§ã³ãï¼ã¢ãã¤ã«ã¨ãï¼ãè¨å®ãã¨ãã
å ·ä½çã«ã¯ããNo-Cache User-Agent Patternã ã®é ç®ã«ã以ä¸ãã³ããã
w3c_validator DoCoMo SoftBank WILLCOM mixi-mobile-converter UP.Browser Playstation iPhone Android BlackBerry Nintendo Nitro PDA Windows CE emobile Opera Mini Opera Mobi PalmOS ia_archive Mobile bot slurp
ããã ããããã¡ãï¼
DB Cache Reloaded Fixã¯ããªã³ã«ãã¦ããã£ãã·ã¥ã®æå¹æéã ã決ãããã¨ããããï¼ï¼åããã£ã¨é·ãã¦ããããã©ã
ã¨ããããããã ãã§ãä¸æ°ã«éããªããï¼
BJ Lazy Load ãå ¥ãã
ç»åãå¤ãã®ã§ããã°ãæ¸ããã°ãããããªãï¼ã¨ããããã§ã
é
延èªã¿è¾¼ã¿ããã¦ããããã©ã°ã¤ã³ã§ãã
ã»BJ Lazy Load
é
延èªã¿è¾¼ã¿ã¯ãè¦ã¯ãç»é¢ã«ã¾ã 表示ããã¦ãªãä¸ã®æ¹ã®ç»åã¯ããããªãèªã¿è¾¼ã¿ã¾ãããï¼ã¹ã¯ãã¼ã«ã«ã¨ããªã£ã¦ãé 次èªã¿è¾¼ã¿ã¾ããï¼ãã¨ãããã¨ã
ã¨ã¦ãã¦ã¼ã¶ã¼ã«åªãããã©ã°ã¤ã³ã§ãã
ããããã©ã°ã¤ã³æå¹ã§ãªãã±ã¼ã ãã©ã
ãTheme loader functionã ãããwp_headerã ã«ããªãã¨åããªãç°å¢ã®äººãããããããã¨ãç 㯠ãwp_footerã ã§ãªãã±ã¼ã ã£ããJSã¯ãªãã¹ãããã¿ã¼ã«ãã£ãæ¹ãããããã§ãã
ã¾ããèªã¿è¾¼ã¿ã追ãã¤ããªãå ´åã¯ã
ãã©ã°ã¤ã³ã® lazy-load.js ã® distance: 200ã 400ãããã«å¤ããã¨è©å¤ããã¿ãããä½ãã¯ã»ã«å
ã¾ã§èªã¿è¾¼ãããã£ã¦ã¨ããã§ããªã
ã¨ãç ï¼coreserverï¼ã¯ããªããã©ããã¦ããããã«è¡¨ç¤ºãããªãããã¼ããè¦æ¤è¨ã
ã¨ããããä¸æçã« content ã®ä¸ã¯é
延ããªããã¨ã«ãããã¾ãæå³ããªããªã£ã¡ãããã©ã
GZIP Output
GZIPå§ç¸®ã¯ãCSSãJSãå§ç¸®ããæè¡ã§è»½ãã§ããããã¯è»½ãããããã¨ããèãæ¹ã
Head Cleanerã§ãã§ããã¯ããªã®ã¨ã.htaccessã¸ã®è¨è¿°ã§ãã§ããã¯ããªãã ãã©ããªãã ããã¾ããããªãã£ãã®ã§ããã¡ãã®ãã©ã°ã¤ã³å°å
¥ã
ã»GZIP Output
ã¡ãªã¿ã«ãGIDZipTestã¯ããèªèº«ã®ãµã¤ããGzipå§ç¸®ã«æåãã¦ãã確èªãããµã¤ãã
ããã¹ãå¨ãã 8kBæ¸ã£ãï¼å¤§ãããï¼
ãã¼ã¿ããã ã£ã CSS Spriteã«ã·ããï¼
ãããããã¯å£°ããã¤ã«ãã¦è¨ããããã¢ãã³ã¹ãã©ãã·ã¥
ãããã¾ããã¹ãï¼
ã¢ã¤ã³ã³é¡ãã²ã¨ã¾ã¨ãã«ãã¦ããã®ãã¡ã®ã©ãããã©ãã¾ã§ãåãåºãã¦ä½¿ãããã¨ããã®ã CSS Spriteã
[ã¨ãç ã®ã¢ã¤ã³ã³ã¹ãã©ã¤ãä¾]
ãªãã ãé£ãããï¼é¢åãããããªå å ¥è¦³ã ããã£ãã®ã ãã©ãå®éã¯è¶ ç°¡åã説æãæ¸ãã¨ããã©ããããããã£ã¦ã¿ãæ¹ãã¹ãããªãããã¨æãã
HTMLã¯ã
<div class="udon"> <i></i> ã¡ãã¥ã¼ã®é ç® </div>
CSSã¯ã
.udon i{ background: url('img/sprite.png') no-repeat 0 -64px; width:30px; height:30px; }
ã¿ãããªæãã
<i>ã css㧠å¿
è¦ãªå¤§ããã«åºãã¦ï¼width 㨠heightï¼ããã®èæ¯ç»åã«ã¹ãã©ã¤ãç»åãå
ã¦ã¦ï¼backgroundï¼ãããã«ãã®ä½ç½®ãæå®ã
èæ¯ç»åã®ä½ç½®æå®ã¯ã好ã¿ã ã¨æããã©ããããããã³ãã¼ã¯ã url()ã«ã¤ã¥ãã¦æ¸ãã¡ããã
ãã®å¾ã® ä¸åç®ã®æ°åãå·¦ããã®ãäºåç®ãä¸ããã®ä½ç½®ã
ç¶æ³ã«ãã£ã¦ã¯ float:left ã足ããªãã¨ãã¾ã表示ã§ããªãã¨ãããã£ãã
ç»åã¯ç¸¦ã«ç¶ãã¦ä¸¦ã¹ã¦ããã®ããããããã¿ããã
次ã®ã¢ã¤ã³ã³ã«ç§»ããã³ã«ãcssä¸ã®ä½ç½®æå®ã¯ãã©ãã©ã -ï¼ãã¤ãã¹ï¼ã«ãªã£ã¦ãã¾ãã
èæ¯ç»åãå ¨é¨ã§ï¼ï¼åèªã¿è¾¼ã¾ãã¦ãã®ã¨ã大ã¾ãã«åããã¹ãã©ã¤ããï¼åèªã¿åºãã®ã¨ããã®ãªã¯ã¨ã¹ãæ°ã®å·®ãçãã¹ãã¼ãã®å·®ã¯ãcoreserverã¿ããã«å¿ ãããæ©ãã¬ã¹ãã³ã·ãã§ã¯ãªããµã¼ãã¼ã§ã¯å¤§ããã§ãã
coresereverã§ã¯ CSS Sprite ã¯å¿ é ã ï¼ã¨æã£ããã
Cloudflare ã¯ãcoreserverã®ããã«å°å ¥è¦éã
ãã¡ããã¡ãã§è©±é¡ã®ç¡æã®CDNãCloudflareã
ä»ã®æ¡ä»¶ã§ããªãããããããããµã¼ãã¼ã«å°å
¥ã«ãã¦ãããã¶ãå¹æãå®æããã®ã ãã©ãããããããã¨ãç ã®ãã coreserver ã«ã¯å°å
¥ã§ãããæ®å¿µï¼
管çç»é¢ããå¼·å¶ã®ãã¿ã³ãï¼é±éã«ä¸åæ¼ãæ¹æ³ãããã¿ããã ãã©ãã¡ãã£ã¨åé¡èµ·ããããªã®ã§ãä¿çã
ãã¡ãã®ãµã¤ãæ§ã詳ããã§ãã
ã»cloudflareã¨coreserverãç¸æ§åé¡ã¯coreserverã®ä»æ§ï¼åæ§ï¼ï¼| technical blog
ç¾ç¶ã§ã¯ã¾ã ãã¢ã¯ã»ã¹æ°ãããã¾ã§å¤ããªããããããã©ãããã¡ããå¢ãã¦æ¥ãã WordPresså°éã®ãµã¼ãã¼ãwpXã«ç§»è»¢ããã¤ãããããã°ããã¼ã
ããããã¼ã¸ã®è¡¨ç¤ºä»¶æ°ãæ¸ãã
ããã¯å½ããåããã¦ãã¾ãè¨ãããªããã©ãå¹æã¯å¤§ããã
æ¨ä»ã®è¨äºã¯ããµã ãã¤ã«ãã¤ãã¦ãããSNSç³»ã®ãã¿ã³ãã¤ãã¦ããã§ãä¸ä»¶è¡¨ç¤ºãå¢ããã ãã§çµæ§ãªãªã¯ã¨ã¹ãã¨ãéä¿¡éãå¢ãã¡ãããã ããã表示件æ°ãæ¸ããã®ã¯ãããªãå¹æçã§ãã
ã¨ãç ã¯ææ°è¨äºï¼ä»¶ â ï¼ä»¶ã¸
人æ°è¨äºãï¼ä»¶ â ï¼ä»¶ã«æ¸ãããã
ããã ãã§ã
ãã
ã«ãªã£ãï¼
ãªã¯ã¨ã¹ããï¼ä»¶æ¸ã£ã¦ããã¼ã¸ã©ã³ã¯ãï¼ä¸ãã£ãããµã¤ãºã¯ 13kBæ¸ã
ããããªã
ç»åã¨ãã¡ã¤ã«ã®æé©åã»ãªãµã¤ãºããã
ã»JPEGminiï¼ç¡æã¦ã§ããã¼ã« 㨠ææã½ãã ï¿¥1,700 JPGåãï¼
ã»Image Alphaï¼ããªã¼ã½ãããPNGåãï¼
ã»Image Optimï¼ããªã¼ã½ãããä½ã§ããEXIFæ å ±åé¤ï¼
ã»s.pressï¼ææã½ãããHTMLãCSSãJSåããï¿¥250ï¼
ããããã¯ãã£ã¨ãImageOptimã®ã¿ä½¿ã£ã¦ãã®ã§ãããä»å JPEGminiã使ã£ã¦ã¿ã¦é©æï¼
ãªãã ãã®ãã¡ã¤ã«ãµã¤ãºã®æ¸ãã£ã·ããphotoshopã§åºåããç»åããããã«æ°åã®ä¸ã¾ã§å§ç¸®ãããããªã®ã«è¦ãç®ã¯ã»ã¼ããããªãç¨åº¦ã®å£åã
ããã¯ã1700åã®ä¾¡å¤ãããã¾ããªãï¼
試ãã«å¤ä»ãHDDã®åçãã©ã«ãã JPEGminiã«å
¥ããããåè¨ 37GBæ¸ã£ãã
ãã²ãã¼ï¼ï¼å ã®ãµã¤ãºã¯ 100GBããããï¼
ãããããImage Alpha 㯠PNGã«ç¹åãã¦ããè²æ°ãé¸ã¹ã¦ãå質ã¨å£åå ·åããªã¢ã«ã¿ã¤ã ã«åæ ãããªããåºåã§ããã®ã§ãã¨ã¦ããããããã¡ããå¤§ä½ 70%ãããå°ãããªãã
Image Optim ã¯ãEXIFæ
å ±ï¼ã©ãã§æ®å½±ããåçãããªã©ã®ä»éæ
å ±ï¼ãæ¶ãã¦ããããã»ãã¥ãªãã£çãªè¦³å¿µããã£ã¦ãæ¯åããã¦ã¾ãã
ä¸è¨ï¼ã¤ãçµãå¾ãImage Optim ã§ããã«å§ç¸®ã§ããã
s.press ã¯ãå æçºå£²ãããã°ã£ããã®ã½ããã¦ã§ã¢ãHTMLã¨CSSã¨JSãå§ç¸®ãã¦ããããçµæ§ã¡ã£ã¡ãããªããçºå£²ç´å¾ã¯ç¡æã»ã¼ã«ããã£ãã®ã§ãããããã¯ããã®ã¨ããã§ããã²ãããã¦ããã¾ãããããããã¯èªåã§ããããã¨ã¯ãªãã ãããã¨ãã JSã CSSãå§ç¸®ããã¤ãã¤ã¨åããã¨ãããåãã¾ããã
å½ç£ã°ãããï¼ããã¡ã® Head Clearner
ããã¾ã§ããã°ã£ã¦ãããããã£ãããã
ããã±ã¢ãã¯è±èªã§ã¹ãã¼ã¹ããã¡ã®å°å
ããã£ã±ãã¹ãã¼ã£ãã
ãã¼ããã¨æãã¤ã¤ãæå¾ã®é ¼ã¿ã®ç¶±ãHead Cleanerã®è¨å®ãè¦ç´ãã¦ã¿ããã¨ã«ã
Head Claener ã¯ãããããã¨ã¯ãããã®ã ãã©ã
ãã¡ããã¨ããã£ã¦ã人ã使ããªãã¨ãããã«ãããæãããã£ã¦ãããããã®ä¸ã§ã¯æãå¤ãåå¨ãªã®ã§ããããããã¨ããããããªããã
ã¨ããããã§ããããããã£ã¦ã¿ã¤ã¤ããã©ã°ã¤ã³æå¹åå¾ãè¨å®ããã
ãGoogle Ajax Libraries ãå©ç¨ãããã«ãã§ãã¯ãä¿åï¼
ãã®çµæããã
ããï¼è¡¨ç¤ºã¹ãã¼ããï¼ç§ãããéããªã£ãï¼
Wordpresså
èµã® jQueryã®èªã¿è¾¼ã¿ãé
ãããã«ãCDNã§ãã Google ajax library ã®æ¹ãããã£ã¨éããªããããªããããã
ãã ãææ°ã®jQuery 1.9ç³»ã¯ãã©ãã«ãããã¿ããã
ãã®ã¾ã¾ã ã¨ã¨ãç ã§ã¯ãããã¤ãåããªããã®ããã£ãããã
header.phpã® <?php wp_head ?> ç´åã«ä»¥ä¸ãæ¸ãã
<?php wp_deregister_script('jquery'); wp_enqueue_script('jquery','http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js'); ?>
1.8.3 ã§ãããã¿ãããªãã ãã©ããªããããã¾ããã¾ãåããªãã£ãã®ã§ã1.7.1ã¾ã§ä¸ããããããã¸ãã¯æ§åè¦ã§ããªã
ã¾ã¨ãï¼
å½åã«æ¯ã¹ãã°è¡¨ç¤ºã¹ãã¼ããããã¼ã¸ãµã¤ãºãåå以ä¸ãªã®ã§ãçµæ§ããããããªãã§ããããã
åé ã® Pingdom website speed testããã«ãã
ãããªãã®ã¦ã§ããµã¤ãã¯ãããã§ãã¹ãããä»ã®ãµã¤ãããããï¼ï¼ï¼
éãã§ãããã£ã¦è¤ãã¦ãããããã
ã¾ã ã¾ã ãã¼ã¸ã°ã¬ã¼ããä¸ãã¦ããªã¯ã¨ã¹ããä¸ãããããã ãã©ããããã¸ãã¯ã¾ã追è¨ãã¾ãã
表示ãéãã¨ãä½ããèªåã®ã¦ã§ããµã¤ããèªåã使ã£ã¦ã¦æ°æã¡ãããããã
SEOçã«ããè¶ éè¦ï¼ã¨ã®ãã¨ãªã®ã§ãé«éåã¯ãå§ãã§ããã
ã¤ã¥ãã¼ï¼ï¼ï¼
- « ã¨ããç 究æã®ãããããã
- » ãã©ãããï¼ï¼å·»ã«åºã¦ãããå¹»ã®ãã©æçãä½ã£ã¦ã¿ãã