Return to Snippet

Revision: 4895
at January 27, 2008 23:16 by Tate


Initial Code
Options +FollowSymlinks
RewriteEngine on
rewritecond %{http_host} ^example.com [nc]
rewriterule ^(.*)$ http://www.example.com/$1 [r=301,nc]
 
rewritecond %{SERVER_PORT} !^443$
rewriterule ^filename\.php(.*)$ https://www.example.com/filename.php$1 [r=301]

Initial URL
http://www.mcgwebdevelopment.com/blog/2008/01/redirect-only-specific-files-from-http-to-https/

Initial Description


Initial Title
Redirect A Single Page To HTTPS Using mod_rewrite

Initial Tags
htaccess

Initial Language
PHP