Wordpress Blog Header Slowness Problem Fix

Yes the blog header, when included in other pages (non-wordpress pages) can REALLY slow down your page loading.

However, the problem was not what I thought it was — the system querying the database for the WP configuration information, and then subsequently executing my own scripts. It always seemed just a little TOO slow for this to be the problem.

In another (what I thought was unrelated) search, I was looking for why I was getting 404 headers being served from all of my pages, that were non-wordpress, but included that pesky wp-blog-header.php file.

Turns out that the old wp-blog-header is a freakin megalomaniac. It wants everything. It was the one sending 404 headers out for my pages that were non-wordpress. This effectively killed my google indexing for pages.

On top of that, it WAS SLOWING THE SYSTEM DOWN when rendering that header, doing extra processing.

Now that that is fixed, my non-wordpress pages render about 3 times as fast.

Hallelujah, Praise be to Allah Krishna Jesus and the cast of ‘That 70s Show’.

Here is a link I found detailing a good fix:

http://trac.wordpress.org/ticket/2984

and thanks to these dudes for telling me about it!

Basically the code, in whatever file that includes the header, should look like something like this (mind the paths):

<?php
define(’WP_USE_THEMES’, false) ;
require(’../../../wp-blog-header.php’); // i’m in wp-content/themes/js.php
header(”HTTP/1.1 200 OK”); // else we get 404
header(”Status: 200 All rosy”) ; // what should this really say?
?>

Bookmark and Share: These icons link to social bookmarking sites where readers can share and discover new web pages.
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google
  • Technorati
  • YahooMyWeb
Tags: , , , , , ,

Related Articles

 

Leave a Reply