legacy-knowledge-base
公開されました Jun. 30, 2025

"HTTP Status 400 – Bad Request" error occured when Updating Blogs' Custom Friendly URL

投稿者

Kartik Singh

knowledge-article-header-disclaimer-how-to

knowledge-article-header-disclaimer

legacy-article

learn-legacy-article-disclaimer-text

Issue

  • While updating the "Blogs" custom-friendly URL from "/liferay-blog" to "test-blogs/liferay-blogs," an HTTP Status 400 - Bad Request error appears on the UI. (A video demonstrating the issue has been attached.)
  • Steps to Reproduce

    1. Start the Liferay bundle.
    2. Navigate to Product Menu > Design > Page Templates > Display Page Template.
    3. Create a new Display Page Template (DPT) and select "Blog Entry" as the type.
    4. Mark the newly created DPT as the default.
    5. Navigate to Product Menu > Site Builder > Pages, and create a page named "Test Blogs" and the default URL will generate "/test-blogs".
    6. Add the "Blog" widget to the page and "Publish" it.
    7. Navigate to Product Menu > Content & Data > Blogs, and create a new blog entry (Liferay Blog), and the default URL will generate "/liferay-blog".
    8. Update the blog's custom "Friendly URL" to "/test-blogs/liferay-blog" and save it.
    9. Access the "Test Blogs" page: The URL generated is "localhost:8080/test-blogs"
    10. After clicking the blog title, the following URL is generated, and an HTTP Status 400 - Bad Request is displayed on the UI:

Observed Behavior: After clicking the blog title, the following URL will generate, and an HTTP Status 400 - Bad Request will display on the UI:

http://localhost:8080/test-blogs/-/blogs/test-blogs%2Fliferay-blog?_com_liferay_blogs_web_portlet_BlogsPortlet_redirect=http%3A%2F%2Flocalhost%3A8080%2Fpersonal-loan-blogs%3Fp_p_id%3Dcom_liferay_blogs_web_portlet_BlogsPortlet%26p_p_lifecycle%3D0%26p_p_state%3Dnormal%26p_p_mode%3Dview

Expected Behavior: After clicking the blog title, the following URL should be generated and the blog should be visible on the UI.

http://localhost:8080/b/test-blogs/liferay-blog

Environment

  • 2024.Q2.0

Resolution

  • The observed behavior has been addressed by: LPD-29742
  • The issue has been fixed in Liferay DXP 2024.Q4.0.

Additional Information

  • If a hotfix is required or any more information on this, please create a support ticket requesting a hotfix by attaching patch details.
  • Installing Fix Packs and Hotfixes on Liferay DXP will guide you to install this hotfix in the respective environment.
did-this-article-resolve-your-issue

legacy-knowledge-base