Pending

User tests: Successful: Unsuccessful:

avatar rish106-hub
rish106-hub
15 Jun 2026

Pull Request resolves #47710.

  • I read the Generative AI policy and my contribution is either not created with the help of AI or is compatible with the policy and GNU/GPL 2 or later.

Summary of Changes

PR #47263 fixed readmore showing when there is nothing to read, but introduced a regression: when introtext_limit is used to truncate text (instead of a readmore marker), $item->fulltext is empty so the readmore button never renders even though the article IS truncated and there IS more to read.

Fix tracks whether truncation actually occurred and uses that flag alongside $item->fulltext to decide readmore visibility.

Testing Instructions

  1. Create an article with only introtext (no readmore marker), body > 100 chars
  2. Create a mod_articles module: set Introtext Limit = 50, Show Read More = Yes
  3. View frontend — readmore button should appear
  4. Shorten article text below limit — readmore button should disappear
  5. Article with readmore marker — unaffected, still shows readmore

Actual result BEFORE applying this PR

No readmore button shown even though text is truncated by introtext_limit

Expected result AFTER applying this PR

Readmore button appears when introtext is truncated. Does not appear when text fits within limit. Articles using readmore marker unaffected.

  • No documentation changes for guide.joomla.org needed
  • No documentation changes for manual.joomla.org needed
avatar rish106-hub rish106-hub - open - 15 Jun 2026
avatar rish106-hub rish106-hub - change - 15 Jun 2026
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 15 Jun 2026
Category Modules Front End
avatar richard67
richard67 - comment - 15 Jun 2026

There is already a PR for the same issue: #47713 .

avatar rish106-hub
rish106-hub - comment - 16 Jun 2026

@richard67 Thanks for flagging #47713.

Our approach differs in a key way: #47713 has an open review comment from @QuyTon noting the fix executes even when show_introtext is disabled.

In this PR, $item->introTextTruncated is initialized to false in the helper and only set to true inside the if ($show_introtext) block — so the template condition is always safe when intro text display is off. This addresses QuyTon's concern.

Happy to close if maintainers prefer to update #47713 instead.

avatar krishnagandhicode krishnagandhicode - test_item - 16 Jun 2026 - Tested successfully
avatar krishnagandhicode
krishnagandhicode - comment - 16 Jun 2026

I have tested this item ✅ successfully on 5621400

Thanks.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/47966.

avatar krishnagandhicode
krishnagandhicode - comment - 16 Jun 2026

I have tested this item ✅ successfully on 5621400

Thanks.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/47966.

avatar rish106-hub
rish106-hub - comment - 16 Jun 2026

@richard67 — adding to my earlier response:

@krishnagandhicode has independently tested and confirmed this PR works correctly on 5621400.

To summarise why this PR addresses the regression more completely than #47713:

  • #47713 has an open review comment from @QuyTon: the fix runs even when show_introtext is disabled
  • In this PR, $item->introTextTruncated is initialised to false before the if ($show_introtext) block and is only set true inside it — so when intro text display is off, the flag stays false and the readmore condition is unaffected

With a passing test and CI green, happy to have this reviewed for merge or to close in favour of a corrected #47713 — whichever the team prefers.

avatar rish106-hub
rish106-hub - comment - 16 Jun 2026

@richard67 — adding to my earlier response:

@krishnagandhicode has independently tested and confirmed this PR works correctly on 5621400.

To summarise why this PR addresses the regression more completely than #47713:

  • #47713 has an open review comment from @QuyTon: the fix runs even when show_introtext is disabled
  • In this PR, $item->introTextTruncated is initialised to false before the if ($show_introtext) block and is only set true inside it - so when intro text display is off, the flag stays false and the readmore condition is unaffected

With a passing test and CI green, happy to have this reviewed for merge or to close in favour of a corrected #47713 - whichever the team prefers.

Add a Comment

Login with GitHub to post a comment