adobe / adobe/aem-core-wcm-components

Page properties "pageTitle" not working

Open
#2,269 3 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
796
Forks
776
Avg merge
3d 22h
Merged PRs (30d)
8

Description

Bug Report

Current Behavior
Page V3:
"pageTitle" in the pageproperties is never used in html markup in <title> field of the page .

Expected behavior/code
pageTitle should be used in <title> field, if nothing is in pageTitle the fallback should be the jcr:title

Description of the page from github Project: ./pageTitle - defines an alternative page title. Used for overriding the ./jcr:title in an on-page context.
https://github.com/adobe/aem-core-wcm-components/tree/main/content/src/content/jcr_root/apps/core/wcm/components/page/v3/page

I'm not sure what the meaning of "on-page context" is. But I think it's the <title> tag on the page.

Also the video from adobe itself on min 1:35, the guy says "pageTitle" should be taken first and jcr:title is the fallback.
https://experienceleague.adobe.com/docs/experience-manager-learn/sites/page-authoring/page-properties-feature-video-understand.html?lang=en

So I think this should be fixed or all videos and descriptions should be changed, what we can use the pageTitle for.

Environment

  • AEM 6.5.13
  • Core Components 2.19.0
  • JRE 11

Possible Solution
I think it can be fixed here https://github.com/adobe/aem-core-wcm-components/blob/main/content/src/content/jcr_root/apps/core/wcm/components/page/v3/page/head.html

just add the pageTitle and the jcr:title as a fallback

Additional context / Screenshots
image
image

image

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with content/src/content/jcr_root/apps/core/wcm/components/page/v3/page/head.html, the file identified in the report, and inspect how the HTML title is currently produced. Confirm that pageTitle takes precedence and jcr:title is used when it is empty; verify the rendered page title in an AEM environment.

Written by the indexing model from the issue text.

Assessment

Tech stack
html
Domain
frontend
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
50/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.