News for hackers. Stuff that matters.
Re:Top Useful .htaccess rewrites, Mod_Rewrite Tricks and Tips by jeremyw on Tuesday April 13, 2010 @11:58AM (#1262382)
Note you can make the www redirect generic across virtual hosts. (And, R=301 or not depending on the circumstance.)

    # non-www -> www"
    RewriteCond %{HTTP_HOST} !^www\."
    RewriteRule .            http://www.%{SERVER_NAME}%{REQUEST_URI} [R,L]"

There are no comments on this comment yet.