Hi John, Thank you for the reply. I also found one more way to do it ... Added the following directive in httpd.conf <Location /private> RewriteEngine On ReWriteCond %{HTTPS} !=on RewriteRule .* https://%{HTTP_HOST}:443%{REQUEST_URI} [QSA,R=permanent,L] </Location> However, now the problem is, I also needed the users to authenticate by htaccess file. But keeping .htaccess file in /var/www/html/private is not working. I mean in that case, first the system asks password in an unsecured mechanism and then only https redirection is working. I wanted just the reverse...first establish secure connection and then only ask the user for password... Any clue on it ?? John Hicks wrote: > > sangfroid wrote: >> Hi, >> >> I have two webpages... >> >> 1. www.mypage.com and >> 2. www.mypage.com/private >> >> The issue that I am having is, I need to redirect all http requests >> coming >> to http://www.mypage.com/private to https://www.mypage.com >> >> However, I don't want the requests coming to http://www.mypage.com to be >> redirected to https://www.mypage.com. >> >> >> How do I accomplish it ? >> >> I will highly appreciate your suggestions..Thanks.. >> > > Simplest solution is the Redirect directive: > From http://httpd.apache.org/docs/2.0/mod/mod_alias.html#redirect : > > The Redirect directive maps an old URL into a new one by asking the > client to refetch the resource at the new location. > > The old /URL-path/ is a case-sensitive (%-decoded) path beginning > with a slash. A relative path is not allowed. The new /URL/ should > be an absolute URL beginning with a scheme and hostname. > > > Example: > > | Redirect /service http://foo2.bar.com/service | > > If the client requests |http://myserver/service/foo.txt|, it will be > told to access |http://foo2.bar.com/service/foo.txt| instead. > > So in your case you would use something like: > > | Redirect /private https://foo2.bar.com/ > | > > | > | > > John > > -- View this message in context: http://old.nabble.com/http-redirection-to-httpd-tp26222774p26223880.html Sent from the Apache HTTP Server - Users mailing list archive at Nabble.com. --------------------------------------------------------------------- The official User-To-User support forum of the Apache HTTP Server Project. See <URL:http://httpd.apache.org/userslist.html> for more info. To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx " from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx