Más contenido relacionado La actualidad más candente (20) Similar a Optimizing WordPress - WordPress SF Meetup April 2012 (20) Optimizing WordPress - WordPress SF Meetup April 20121. WordPress
Optimization
WordPress Optmization
Ben Metcalfe | Co-founder, WP Engine
@dotBen | ben@wpengine.com
San Francisco WordPress Meetup – April 23rd 2012
5. WordPress
Optimization
Why?
• Um, why not?
• Keep readers/customers happy!
• Stay up under heavy load
• Save $$$
10. WordPress
Optimization
Avoid bad plugins
Include (but not limited to)
• backupwordpress
• backwpup
• broken-link-checker
• dynamic-related-posts
• file-commander
• google-sitemap-generator
• LinkMan (MyReviewPlugin Link Man)
• MyRP (MyReviewPlugin)
• wp-symposium-alerts
11. WordPress
Optimization
Review your theme
HTML
• does it validate?
• CSS at the top, JS at the bottom (not inline)
PHP
• Any weird code (if it looks bad, it probably is)
• file_get_contents() / fgets()
17. WordPress
Optimization
Load from multiple sub-
domains
good:
foo1.yourdomain.com, foo2.yourdomain.com
better:
foo1.otherdomain.com, foo2.otheromain2.com
18. WordPress
Optimization
Browser Caching
HTTP Cache-Control
Expires headers
Entity Tags
(W3-Total-Cache, WPSuperCache)
22. WordPress
Optimization
CDN
MaxCDN (we use parent company @ WP Engine)
Amazon CloudFront
CloudFlare
Use all the time or just „emergencies‟
28. WordPress
Optimization
Reverse-proxy with
nginx
Run Apache on port 8080
Cache statics
(good HOWTO on wp-performance.com)
29. WordPress
Optimization
Varnish cache
Save/server static pages to/from disk
Ideally don‟t run Varnish on port 80,
Avoid cookie issues
30. WordPress
Optimization
Memcache
Cache WordPress Object Cache
Memcached plugin + PECL memcache
extension
Ideally run Memcache on separate box
wp-memcached-manager – admin plugin
31. WordPress
Optimization
HyperDB
Replaces wpdb class
Multiple database servers
Replication + failover for redundancy
Partitioning for scale
35. WordPress
Optimization
DON‟T edit core files!
No matter what “performance” benefit you think
it will make!