Can you really have apache obtain a request like whateverProtocol://localhost and redirect it to http://localhost?

Thanks ahead of time.

Update: Appreciate the solutions. Particularly, I'm attempting to redirect ldap : // localhost to http : // localhost -- but ldap might be identified by mod_rewrite. But no luck to date using RewriteEngine/RewriteRule, including using RewriteCond SERVER_PROTOCOL...

Any ideas could be greatly appreciated.

I do not observe how this might possibly work. Apache is definitely an HTTP server, no LDAP server, therefore it wouldn't obtain the request to begin with. Even when you'd it serve demands for port 631, an LDAP client wouldn't send an HTTP request and wouldn't have the ability to parse a redirect response.

Generally, no. Most methods don't incorporate a way of redirecting to another one.

Within the situation of HTTPS, you are able to. That's simply dependent on:

Redirect 301 / http://localhost/

… within the configuration for that HTTPS virtual host.

update in reaction to edit:

Even though it is theoretically easy to persuade Apache to speak to LDAP (modules for this may use it as being the bottom for just about any type of TCP/IP server), LDAP clients don't talk HTTP, so this type of redirect wouldn't make sense at all. (I do not think LDAP supports a redirect response either).

mod_rewrite appears to become what your lookiing for:

http://httpd.apache.org/docs/2.2/mod/mod_rewrite.html

Hope this really is of outside assistance