So Google’s Page Speed Service¬†looks pretty great – but if you get into the beta and upload a lot of media to your WordPress site, you’re going to run into a few snags. The cap for their caching proxy is currently set at 2MB. And while that’s fine for most folks, it’s not really going to fly for photobloggers and the like.

Fortunately, there’s a workaround…

All you need to do is create a subdomain (like admin.domain.com)¬†and point it at your current WordPress install’s directory. If you don’t know how to do this, your web host’s support should be able to help you out.

Now you’ll notice that when you visit that new URL, you’ll get redirected to your main domain. WordPress needs to know to not do that, so just add this code to your “wp-config.php” file:

define('WP_HOME', 'http://'.$_SERVER['HTTP_HOST']);
define('WP_SITEURL', 'http://'.$_SERVER['HTTP_HOST']);

It doesn’t really matter where you drop it, but I like to put this sort of stuff after the MySQL information. Then just save out the file, kill your browser cache and try to visit your subdomain now.

So long as things don’t keep trying to redirect you, log into your WordPress Dashboard (admin.domain.com/wp-admin/) and you should be able to post and upload files without any issues.

Simple enough, right?