Forum Moderators: phranque
I've tried the following in .htaccess:
Redirect 301 /directory/script.cgi https://mydomain.com/directory/script.cgi
It seems that this redirects repeatedly until the redirection limit is exceeded.
Is there any other good way to redirect a non-secure page to the secure location?
Thanks,
Matthew
It seems that this redirects repeatedly until the redirection limit is exceeded.
Yes it would. The "from" field is a local path, so the redirect is being triggered anytime you go to that page, with or without the "s" after http.
You need to do this using mod_rewrite I think. This thread maybe better off in the Apache Web Server forum.
<Added>
Does this help:-
[webmasterworld.com...]
....?
</Added>
TJ
Any further ideas on how to accomplish this would be great!
Thanks,
Matthew
Options +FollowSymLinks
RewriteEngine on
RewriteCond %{SERVER_PORT} !^443$
RewriteRule ^directory/script\.cgi$ https://mydomain.com/directory/script.cgi [R=301,L]