Redirect 301 not working with dynamic URL

Judd Pickell pickell at gmail.com
Fri May 22 15:20:37 MST 2009


Two thoughts, but don't quote me on it as it has been awhile since I have
played with the redirect rules for apache.

1) You aren't receiving an error because near as I can tell your syntax is
correct for your redirect line.
     Ex: Redirect <NUM> <STRING_EXPRESSION> <URL_LOCATION>

Short of you actually putting in an incorrect syntax on the line, you
shouldn't receive an error. It just will never match it.

2) Are you sure that the actual command sent to your server is formatted as
you are wanting to test? If you are using a CMS that is using mod_rewrite
rules the actual GET/POST string sent to the server may differ from what you
are attempting to catch. However they all point back to index.php so it
always catches that rule.

Sincerely,
Judd

On Fri, May 22, 2009 at 3:01 PM, keith smith <klsmith2020 at yahoo.com> wrote:

>
> Hi All,
>
> I'm working on an .htaccess file.
>
> The problem I have is :
>
> If I set up
>
> Redirect 301 /index.php?display=contact
> http://www.domain.tld/contact-us.php
>
> It does not redirect nor do I see an error in the logs.
>
> If I configure it this way it will redirect :
>
> Redirect 301 /index.php http://www.domain.tld/contact-us.php
>
> By removing the "?display=contact" I get the index.php to redirect to the
> contact-us.php page.
>
> We have moved from internal dynamic pages to external static pages for
> several reasons.  The main being SEO.
>
> Any idea why the first example causes no error and does not work either?
>
> Thanks for your help
>
> Keith
>
>
>
> ---------------------------------------------------
> PLUG-discuss mailing list - PLUG-discuss at lists.plug.phoenix.az.us
> To subscribe, unsubscribe, or to change your mail settings:
> http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.PLUG.phoenix.az.us/pipermail/plug-discuss/attachments/20090522/427ce965/attachment.htm 


More information about the PLUG-discuss mailing list