Legacy Knowledge Base
公開されました Jul. 2, 2025

リファラー サイトが同じ言語をサポートしていない場合、ローカライズされた仮想ホストからサイトを管理するときに 404 Not Found エラーが発生する

Written By

Jorge García Jiménez

How To articles are not official guidelines or officially supported documentation. They are community-contributed content and may not always reflect the latest updates to Liferay DXP. We welcome your feedback to improve How To articles!

While we make every effort to ensure this Knowledge Base is accurate, it may not always reflect the most recent updates or official guidelines.We appreciate your understanding and encourage you to reach out with any feedback or concerns.

Legacy Article

You are viewing an article from our legacy "FastTrack" publication program, made available for informational purposes. Articles in this program were published without a requirement for independent editing or verification and are provided"as is" without guarantee.

Before using any information from this article, independently verify its suitability for your situation and project.

問題

ある言語が構成されているサイトから、その言語をサポートしていない他のサイトに移動すると、404 エラーが表示されます。

  1. サイト「Site-us」を作成し、デフォルト言語を英語に設定します。 他の言語を削除します。
  2. 「Site-us」設定から、公開ページ/英語の仮想ホストを構成します: site-us.liferay.com。
  3. 「Site-us」に空の公開ページ /home を作成します。
  4. 別のサイト「Site-es」を作成し、スペイン語をこのサイトのデフォルト言語として設定し、他の言語も削除します。
  5. 「Site-es」に空の公開ページ /home を作成します。
  6. site-us.liferay.com:8080 にアクセスしてサインインします。
  7. サイト ページの管理に移動し、サイト セレクターを使用して [Site-es] を選択します。
  8. 404 エラーが表示されます。

Environment

  • ライフレイDXP 7.2、7.3

解決策

  • サイトで URL ロケールがサポートされていない場合に 404 を表示しないようにするには、次のプロパティを設定します。
    locale.use.default.if.not.available=true
Did this article resolve your issue ?

Legacy Knowledge Base