how to do 301 redirect of the same URL with a difference in hypen

adit

I have two links that are actually the same content, for some reason google traced it as two URL, one is:

http://www.shopious.com/items/818526/Celine-Trapeze-mini-Suede-1-warna-saja-185rb-

and the other one is:

http://www.shopious.com/items/818526/Celine-Trapeze-mini-Suede-1-warna-saja-185rb

I basically wanted to redirect the one that has the - at the end to the one that doesn't have the - . How can I do this in nginx?

anubhava

You can use this rule :

rewrite ^/(items/[0-9]+/.+?)-$ /$1 permanent;

이 기사는 인터넷에서 수집됩니다. 재 인쇄 할 때 출처를 알려주십시오.

침해가 발생한 경우 연락 주시기 바랍니다[email protected] 삭제

에서 수정
0

몇 마디 만하겠습니다

0리뷰
로그인참여 후 검토

관련 기사

분류에서Dev

301 redirect complete url to different extension, BUT with exceptions

분류에서Dev

Redirect 301 in htaccess changes the url encoding

분류에서Dev

HTACCESS 301 redirect issue with strange url variables

분류에서Dev

how to redirect the URL in magento?

분류에서Dev

Spring + Tiles. How to return 301 redirect (instead of 302) in Controller

분류에서Dev

301 .htacess redirect issue

분류에서Dev

301 redirect for all get request

분류에서Dev

301 Redirect a folder to a single page

분류에서Dev

htaccess 301 redirect -- remove a string

분류에서Dev

htaccess 301 redirect — remove a path

분류에서Dev

301 Redirect to a 302 Redirect (SEO implications)

분류에서Dev

How to do html redirect in JSP?

분류에서Dev

Difference between jsp redirect url tag and response.sendRedirect() method

분류에서Dev

How to redirect a URL to a custom IP address?

분류에서Dev

Redirect 301 on changed root name not working

분류에서Dev

htaccess redirect 301 https www to non www

분류에서Dev

How to redirect external URL, which is followed by mysite URL

분류에서Dev

How to redirect different URLs to different ports on the same domain?

분류에서Dev

Response.Redirect (url)는 firefox 개발자 콘솔에 301과 302를 보여줍니다.

분류에서Dev

Redirect but keep the domain the same

분류에서Dev

How can a referrer be the same as the current url?

분류에서Dev

How do I display url

분류에서Dev

Node.js: 301 redirect non-www without express

분류에서Dev

htaccess 301 Redirect Wildcard for New Base Domain Name

분류에서Dev

.htaccess 500 internal server error when adding simple 301 redirect

분류에서Dev

Redirect to URL from CoffeeScript

분류에서Dev

Express sendfile and redirect url

분류에서Dev

How do regular expressions work in htaccess to redirect an IP range

분류에서Dev

How do not redirect to /public_html if request is equaled /abc/* for example?

Related 관련 기사

  1. 1

    301 redirect complete url to different extension, BUT with exceptions

  2. 2

    Redirect 301 in htaccess changes the url encoding

  3. 3

    HTACCESS 301 redirect issue with strange url variables

  4. 4

    how to redirect the URL in magento?

  5. 5

    Spring + Tiles. How to return 301 redirect (instead of 302) in Controller

  6. 6

    301 .htacess redirect issue

  7. 7

    301 redirect for all get request

  8. 8

    301 Redirect a folder to a single page

  9. 9

    htaccess 301 redirect -- remove a string

  10. 10

    htaccess 301 redirect — remove a path

  11. 11

    301 Redirect to a 302 Redirect (SEO implications)

  12. 12

    How to do html redirect in JSP?

  13. 13

    Difference between jsp redirect url tag and response.sendRedirect() method

  14. 14

    How to redirect a URL to a custom IP address?

  15. 15

    Redirect 301 on changed root name not working

  16. 16

    htaccess redirect 301 https www to non www

  17. 17

    How to redirect external URL, which is followed by mysite URL

  18. 18

    How to redirect different URLs to different ports on the same domain?

  19. 19

    Response.Redirect (url)는 firefox 개발자 콘솔에 301과 302를 보여줍니다.

  20. 20

    Redirect but keep the domain the same

  21. 21

    How can a referrer be the same as the current url?

  22. 22

    How do I display url

  23. 23

    Node.js: 301 redirect non-www without express

  24. 24

    htaccess 301 Redirect Wildcard for New Base Domain Name

  25. 25

    .htaccess 500 internal server error when adding simple 301 redirect

  26. 26

    Redirect to URL from CoffeeScript

  27. 27

    Express sendfile and redirect url

  28. 28

    How do regular expressions work in htaccess to redirect an IP range

  29. 29

    How do not redirect to /public_html if request is equaled /abc/* for example?

뜨겁다태그

보관