Rewrite/redirect issue

James Read jamesread5737 at gmail.com
Thu May 6 16:05:36 UTC 2021


On Thu, May 6, 2021 at 4:02 PM Sergey A. Osokin <osa at freebsd.org.ru> wrote:

> Hi Eric,
>
> hope you're doing well these days.
>
> On Thu, May 06, 2021 at 02:01:40PM +0000, Eric Speake wrote:
> > I am trying to redirect mydomain.com/summersummit to
> new.mydomain.com/events/employee-events/summersummit2021. Here is what I
> have in my config:
> >
> >    location  /summersummit {
> >    return 301
> https://new.mydomain.com/events/employee-events/summersummit2021;
> >    }
>
> This one should work.
>
> > I have also tried:
> > rewrite ^/summersummit/(.*)$
> https://new.dmp.com/events/employee-events/summersummit2021 permanent;
> > But the redirect doesn't work. It still goes to
> mydonain.com/summersummit.
>
> Could you explain a reason of this second one.
>

Is it anything to do with the typo?


>
> Thank you.
>
> --
> Sergey Osokin
> _______________________________________________
> nginx mailing list
> nginx at nginx.org
> http://mailman.nginx.org/mailman/listinfo/nginx
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.nginx.org/pipermail/nginx/attachments/20210506/4c622bca/attachment.htm>


More information about the nginx mailing list