Archive for September 2008

 
 

lighttpd rewrite rules for wordpress

I found this very informative post about lighttpd mod-rewrites for Wordpress, written by Hinrik Örn Sigurðsson.

Create a file called wp-rewrite.conf in your lighttpd config folder:

url.rewrite-once = (
    "^" + wpdir + "(wp-.+).*/?" => "$0",
    "^" + wpdir + "(sitemap.xml)" => "$0",
    "^" + wpdir + "(xmlrpc.php)" => "$0",
    "^" + wpdir + "keyword/([A-Za-z_0-9-])/?$" => wpdir + "index.php?keyword=$1",
    "^" + wpdir + "(.+)/?$" => wpdir + "index.php/$1"
)

Then include the above file in the $HTTP["host'] section of the specific domain’s config file:

$HTTP["host"] =~ "mydomain.com" {
    var.wpdir = "/"
    include "wp-rewrite.conf"
}

Just make sure that you remove any existing rules in .htaccess, that caused some problems on my side.

fridaytraffic

Every new project has its own challenges and opportunities. This time round, the latter will be fully embraced!

Technologies being used include Flex and Ruby (Rails to a lesser extend). As a newcomer to Flex, my experiences with it will be posted here, with links to resources and the like.