Never been to TextSnippets before?

Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world (or not, you can keep them private!)

Wordpress clean URLS with Lighttpd, the E-Z way (See related posts)

This single line seems to work for my WP install. I needed to add a couple of redirects and rewrites to handle my RSS feed, since I use Feedburner, but this line does all the heavy lifting...

Place it after server.document-root, either in the main section or in your virtual host sub-sections...

server.error-handler-404 = "/index.php?error=404"



Comments on this post

jason posts on May 29, 2005 at 21:03
Yes, and make sure that in wp-admin you don't do the example

/index.php/%year%/%monthnum%/%day%/%postname%/


but instead just

/%year%/%monthnum%/%day%/%postname%/
giovanni posts on Nov 08, 2005 at 23:03
If Wordpress is in a subdirectory of your site's root use something like:

server.error-handler-404 = "/wordpress/index.php?error=404"





mmayo posts on Nov 30, 2005 at 02:16
I tried the above, and although pretty urls work now, my lighttpd error log is littered with this:

2005-11-29 20:05:08: (connections.c.1383) Warning: Either the error-handler returned status 404 or the error-handler itself was not found: /team/index.php?error=404
2005-11-29 20:05:08: (connections.c.1385) returning the original status 404
2005-11-29 20:05:08: (connections.c.1387) If this is a rails app: check your production.log



Normal? I'm pretty sure I did this with lighttpd v1.3.16 (or so)and didn't get the warnings but now I'm running lighttpd 1.4.8.

You need to create an account or log in to post comments to this site.


Related Posts