homepage Welcome to WebmasterWorld Guest from 23.20.149.27
register, free tools, login, search, subscribe, help, library, announcements, recent posts, open posts,
Subscribe to WebmasterWorld

Home / Forums Index / Code, Content, and Presentation / WordPress
Forum Library, Charter, Moderators: lorax & rogerd

WordPress Forum

This 31 message thread spans 2 pages: 31 ( [1] 2 > >     
Wordpress is slow
edacsac




msg:4286408
 5:50 pm on Mar 23, 2011 (gmt 0)

I've been doing tests loading my wordpress site on browsers which do not have my site cached. Half the time it's quick, half the time it could literally take up to four minutes to load.

This particular site is media heavy with photography right now. I have the nextge4n gallery plugin and podpress plugin. The nextgen gallery plugin is configured to spit out 50 thumbnails in the right column (2-3k per thumb). I haven't used podpress yet, but I'm getting there. I mention podpress because it's included .js file is huge. Actually so is nextgen gallery's.

While my site is pretty large with all the thumbnails - not even counting the larger images as part of articles and layout graphics, I'm still much lighter than some popular media heavy sites that load in well under 30 seconds.

I've used some of those speed test sites that give details, and I do see where some problems lie, but there is little to change since everything is needed or as far as images, what I want on my site and the plugin requirements. Once I start really using podpress I'm sure I'll get a chance to clean it up a bit, but right now I'm really frustrated. The site is just how I want it, but I feel powerless to speed it up.

Just looking for wordpress suggestions before I weight it down even further with podcasts and larger scale images.

***Edit to add:
The real issue with the long load times is that the page doesn't trickle in; it stays blank, then loads everything all at once.

 

g1smd




msg:4286477
 8:49 pm on Mar 23, 2011 (gmt 0)

If you have many images, then some simple changes to your .htaccess file could make a big difference. There's several prior threads including [webmasterworld.com...] and [webmasterworld.com...] .

Please test these things out and add your comments both here and to the discussion at [core.trac.wordpress.org...] too.

rocknbil




msg:4287449
 3:39 pm on Mar 25, 2011 (gmt 0)

Better yet, his one-liner mentioned here [webmasterworld.com] is more or less perfect for WordPress. you'll need to append it for any directories you need to access, example,


RewriteCond %{REQUEST_URI} !^\/*wp\-admin\/*$
RewriteRule ^([^.]+)$ /index.php [L,QSA]

The key being:

Since you will never have extensionless "files" in the server filesystem, the rewrite for that can be optimised to one line:


I had one WP customer who's site was horribly slow, and can attest . . . this fixed *most* of it.

If your theme uses Cufon or heavy Javascript libraries, no help there, it will be slow.

You can also try the SuperCache plugin that generates HTML instead of running the WP code with every request.

g1smd




msg:4288238
 8:42 pm on Mar 27, 2011 (gmt 0)

RewriteCond %{REQUEST_URI} !^\/*wp\-admin\/*$
RewriteRule ^([^.]+)$ /index.php [L,QSA]

A couple of minor optimisations:

RewriteCond %{REQUEST_URI} !/wp-admin/
RewriteRule ^([^.]+)$ /index.php [L]


No need to escape slashes or hyphens.
The * and anchoring is not required.
[QSA] is the default action. [L] is still required.

chalkywhite




msg:4291202
 3:14 pm on Apr 2, 2011 (gmt 0)

Do you use a cache plugin like w3tc? I added that to my blog, setup minification and all the usual cache settings and the site no loads in 2 seconds flat was really impressed.

edacsac




msg:4300487
 4:38 pm on Apr 19, 2011 (gmt 0)

I made some htaccess file changes and things where better I thought, but it's a random occurrence. Just now I loaded up my site from work - over 5 minutes to load. Switched to a different post within my page: 3 minutes to load up. Then all of a sudden it was back to 2-5 seconds. But this happens everyday. I generally won't wait 1 minute for a page to load, even if the odds are 1 in 10 times it will be slow.

I think I'm going to dump wordpress. Any ideas on transferring the setup to another CMS? My only problem will be my photo gallery plugin; they don't make one for other cms's, and the work to start over will be tremendous.

edacsac




msg:4300504
 5:03 pm on Apr 19, 2011 (gmt 0)

Page is up, click a link to an article, 5 minutes pass easily. But once that 5 minutes passes, subsequent requests go much faster. Leave the page alone for 10 minutes, click a link and 5 to 7 minutes again, but after that it speeds up. wtf?

Anyone recommend a reliable speed test website better than www.websiteoptimization.com ot ping tools? I'm using a large site as comparison, and both of those sites give errors about objects to large with my comparison site.

rocknbil




msg:4300527
 5:23 pm on Apr 19, 2011 (gmt 0)

Increase memory limit for PHP? Shared hosting? Poor mySQL setup at the host?

Is it your theme? I had a nightmare with one heavily Javascripted theme. Disable Javascript and browse it (brace yourself, it may look horribly broken) and see if it's still slow.

Temporarily swap to a bare-bones-nothing theme, no graphics. "Objects too large" sounds like it's loading huge images - which is entirely likely, if it's not using actual thumbs it could be loading full images in thumbnail sized containers.

I really don't think it's WP. WP seems a bit inefficient, could be faster, but in most environments I've worked with it is not ridiculously slow.

enigma1




msg:4304123
 2:44 pm on Apr 26, 2011 (gmt 0)

I would also check the server logs. Check if there is traffic that pretty much wastes your server's bandwidth. If so you better deploy something to filter it.

Assuming you have tested the blog in a local system and you know there are no latencies.

edacsac




msg:4311398
 4:23 pm on May 12, 2011 (gmt 0)

Thanks for all the help on this. Maybe it's time to switch host.

I've disabled my image gallery plugin and tested right after; site is quick as can be. Then I re-enable the plugin, and the site is quick as can be. It is so random that I can't figure it out. Log files are clean. I have yet to run it on a local system, but that will be a time consuming test.

I also installed habari with 5 of my articles, 5 images, no plugins. Was going good for awhile, then some tests would take 5 minutes for the page to load.

Panthro




msg:4314172
 3:18 pm on May 18, 2011 (gmt 0)

RewriteCond %{REQUEST_URI} !/wp-admin/
RewriteRule ^([^.]+)$ /index.php [L]


@ g1smd - So this bit of code you suggest should just be added to an .htaccess file in every directory? Thank you.

jk3210




msg:4314240
 4:57 pm on May 18, 2011 (gmt 0)

I have the same problem as edacsac.

On one set-up I have one main site and 4 add-on sites. All five are WP. The add-on sites usually run fine, but the main site is similar to what edacsac describes. (Not nearly as bad, but similar).

What is REALLY strange is this: When the site does hang and fail to load (white screen with the "wait cursor" spinning), if I hit the "stop" button in FF and do a View --> Page Source, the ENTIRE HTML is there! Everything right down to the bottom comment that says "<!--WP-Super Cache loaded in 1.745 seconds" is all there. The HTML is there, but the site won't display. Then for the next 2 or 3 hours the site runs fine and loads in 2-5 seconds.

Techs from my ISP (HG) have been all over the site numerous times and found no problems.

GA "Site Speed" reports various page load times from 2-seconds up to 43-seconds.

I've tried: WP-Super Cache, W3TC, and now Hyper Cache. Same intermittent problem.

I'd go for a Ded server in a heartbeat if I thought that would solve the problem, but I'm not sure it would.

rocknbil




msg:4314788
 4:53 pm on May 19, 2011 (gmt 0)

What happens when you disable Javascript? If you can see the entire source code and the page is not rendering, that's the first thing I'd try.

There is the possibility your browser has cached the source code though, which could lead you to a faulty conclusion. If you clear your cache and can still see the source while it's not loading, see first suggestion.

jk3210




msg:4314917
 8:41 pm on May 19, 2011 (gmt 0)

Thanks rock, I'll try that next time it hangs. For now it's looking like Hyper Cache and "DB Reloaded Cache Fix" running together may be improving things quite a bit. GA started out reporting an average load time of 15+ seconds with some pages as high as 43 seconds. But now it's down to an average of 4-6 seconds, so, if that holds, I'll be happy.

rogerd




msg:4314949
 10:01 pm on May 19, 2011 (gmt 0)

There are a bunch of online tools to check what all a page is loading, and tools like Fiddler, Yslow, etc. that run locally. They should very quickly highlight what's slowing the page down. Then, you can determine the best strategy - cache, CDN, or removal of the problematic content. I've seen external ad tags kill page loads, tracking scripts too. Iframing the problematic stuff can at least ensure that a problem at the ad server won't result in blank pages on your site.

If you are running plugins, disabling them all and turning them back on one at a time might be worth a try, too.

jk3210




msg:4315014
 1:03 am on May 20, 2011 (gmt 0)

Yes, I've been using several including Pingdom to check loading times. But this has been a very screwy problem in that I'll check a page and get a loading time of 4.2 seconds, then a few minutes later the same page takes 45 seconds.

As for plugins, I just disabled everything except Akismet and that helped tremendously, so I enabled Hyper Cache, "DB Reloaded Cache Fix" and All in One SEO. As of now I'm getting a consistent load time of 4 seconds, so that may have been the problem all along and things are looking better now.

I'll see what GA comes up with tomorrow for today's Site Speed.

(The bad news is that I've already sent donations to the authors of all those nifty little plugins I was using. Oh well...)

indyank




msg:4315150
 8:31 am on May 20, 2011 (gmt 0)

"DB Reloaded Cache Fix" - Does it work really? I faced issues when i installed it the last time and i had to deactivate it. I also found several people reporting similar issues.

jk3210




msg:4315210
 12:58 pm on May 20, 2011 (gmt 0)

There's two different versions out there..."DB Reloaded Cache" and "DB Reloaded Cache Fix" which is the one I'm using, and so far it has worked okay.

edacsac




msg:4315337
 3:22 pm on May 20, 2011 (gmt 0)

I use yslow, pingdom and another speed checker, and they all report really good results. Even when I'm waiting "minutes" for the page to show, the varies tool results will show barely a couple of seconds locad time. I'm curious to disable javascript, but if javascript is the problem, I'm in a pretty big mess since I'll have to scrap plugins I'm using (nextgen gallery and podpress).

jk3210




msg:4315354
 3:50 pm on May 20, 2011 (gmt 0)

I had an opportunity to try rocknbil's suggestion of disabling Javascript several times last night and unfortunately it didn't help.

It did make for one scary looking website, though. ;)

rogerd




msg:4315361
 4:08 pm on May 20, 2011 (gmt 0)

OK, so maybe there's a clue, edacsac. The tools show a fast pageload but you experience a slow actual browser load. Is there any framed content? Something being pulled from an external source that isn't getting caught by the speed tools?

edacsac




msg:4315371
 4:18 pm on May 20, 2011 (gmt 0)

I do have adsense baked into the top and bottom of every article - inside the wordpress post. But that is it, a 4 link text ad at the top and a 2 link text ad at the bottom. I guess I need to remove those and test...

indyank




msg:4315386
 4:39 pm on May 20, 2011 (gmt 0)

Adsense has implemented asynchronous loading now and you shouldn't be facing any blocking issues anymore.

indyank




msg:4315388
 4:40 pm on May 20, 2011 (gmt 0)

jk3210, thanks. will give it a try.

edacsac




msg:4315418
 5:23 pm on May 20, 2011 (gmt 0)

I installed DB Reloaded Cache Fix, but nothing has changed. Does it take awhile to start noticing a difference?

jk3210




msg:4315424
 5:38 pm on May 20, 2011 (gmt 0)

1.) It takes at least one page-load in order to cache the DB requests for a page.

2.) I'm pretty sure you have to be logged-out of your site to see any affect. (You can look at the bottom of the HTML to see if it worked on any particular page load. So you would have to install it, log out of your site, load a page, THEN reload the page to see any effect. It's the second reload that shows any improvements you'll get from it.

3.) DB Reloaded Cache Fix by itself will only provide a small boost in performance. Hyper Cache is what did the most for me. As I recall, DB Reloaded Cache Fix by itself wasn't even noticeable.

jk3210




msg:4315714
 3:36 pm on May 21, 2011 (gmt 0)

Yesterday GA reported an average page load time of 4.14 seconds, with times ranging from 2.08 to 7.58 seconds.

I had to clear Hyper Cache's entire page cache several times yesterday due to some global structural changes I made to the site, so I'm thinking that the average load time will come down even more when I check it tomorrow.

Things are looking better. However, when I'm logged-in to the site (which means I'm not getting cached pages) I still experience the same thing that edacsac describes. Saving a post update takes anywhere from 5 to 45 seconds.

lorax




msg:4317997
 3:50 pm on May 26, 2011 (gmt 0)

Move your scripts to the bottom of the code. Be sure the key scripts necessary for rendering the page are loaded first in that position followed by any scripts that add useful functionality. You can reduce page load speed a LOT by doing this. Especially any script that use jQuery or other similar library. Also be sure you're not loading these libraries more than once. Optimize the scripts for quick and efficient loading.

Davidcjmad1




msg:4333353
 11:46 pm on Jun 30, 2011 (gmt 0)

Google speeding up wordpress with flush.
Look at WP minify to reduce calls if you have multiple scripts.
Look at self hosting CDN also so the browser will do more paralell downloading

Also get the yslow tool for firefox so you can start to see what is happening. It will tell you for example if your content is being gzipped.

I did a lot of research on WP speed and people quite often focus on what the server is doing and not how the browser is interacting with it. For whatever reason i found W3TC etc. slowed my site ( although im sure it might help smooth the bumps in a spike). I was able to move from an average 3 second load to 1.5 when i started to tweak based on what yslow was telling me. Oy yeah make sure your using browser caching where you can, even if your only setting the times at an hour it will help especially from the second page load and on.

guoyongqiang




msg:4333509
 9:36 am on Jul 1, 2011 (gmt 0)

My this software and you are same, appeared the same question. Thank you for your questions and phenomenon.

This 31 message thread spans 2 pages: 31 ( [1] 2 > >
Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / WordPress
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About
© Webmaster World 1996-2014 all rights reserved