AEM이 내부 페이지의 리디렉션 URL에 '.html'을 추가합니다.

이 문서에서는 AEM이 내부 페이지의 리디렉션 URL에 '.html'을 추가하는 문제를 해결합니다. 이 문제는 리디렉션 대상이 동일한 AEM 내의 공간인 경우 발생합니다.

설명 description

환경
Experience Manager

문제/증상
AEM adds .html to the URL fragment (or anchor, the last part of the URL starting from #). For example:

/content/we-retail/us/en/men.html#FEATURED -> /content/we-retail/us/en/men.html#FEATURED.html

Steps to reproduce:
1-Create a new content page page1 under /content/we-retail.
2-Select page1 > Properties.
3-In Advanced tab > 'Redirect' field, set '/content/we-retail/us/en/men.html#FEATURED'.
4-Access page1 with 'View as Published'.
$  curl -v -u admin:admin http://localhost:6402/content/we-retail/page1.html?wcmmode=disabled
* About to connect() to localhost port 6402 (#0)
...
>
< HTTP/1.1 302 Found
< Date: Mon, 29 Jun 2020 08:21:19 GMT
< X-Content-Type-Options: nosniff
< Content-Type: text/html;charset=utf-8
< Location: http://localhost:6402/content/we-retail/us/en/men.html#FEATURED.html?wcmmode=disabled
< Content-Length: 0
<
* Connection #0 to host localhost left intact

해결 방법 resolution

이것은 하드 코딩된 동작입니다. 다음 com.day.cq.wcm.foundation.impl.PageRedirectServlet#doGet 추가 중 .html 리디렉션 대상이 동일한 AEM 내의 공간인 경우 리디렉션 URL로 리디렉션됩니다.

recommendation-more-help
3d58f420-19b5-47a0-a122-5c9dab55ec7f