Hi - I don't have an answer on this, but a good article on mod Rewrite was in the latest issue of PHP|architect. Advise if you need a copy. Best Regards - Rick ============ [EMAIL PROTECTED]
_____ From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Cliff Hirsch Sent: Wednesday, December 05, 2007 1:59 PM To: NYPHP Talk Subject: [nyphp-talk] Canonical hostname help If I want to redirect domain.com to www.domain.com (or for that matter anything.domain.com to www.domain.com I have figured out (but not tested) the following so far: <IfModule mod_rewrite.c> RewriteEngine on RewriteCond %{HTTP_HOST} ^domain\.com$ [NC] RewriteRule ^(.*)$ http://www.domain.com/$1 [L, R=301] </IfModule> But what about https? How can I make the redirect work for both http and https transactions, redirecting http to http and https to https? Cliff
_______________________________________________ New York PHP Community Talk Mailing List http://lists.nyphp.org/mailman/listinfo/talk NYPHPCon 2006 Presentations Online http://www.nyphpcon.com Show Your Participation in New York PHP http://www.nyphp.org/show_participation.php
