DynamicPageList3 icon indicating copy to clipboard operation
DynamicPageList3 copied to clipboard

Use linktarget table instead of categorylinks.cl_to for MW 1.45+ compatibility

Open hexmode opened this issue 5 days ago • 2 comments

MediaWiki 1.45+ changed the categorylinks table schema to use the linktarget table instead of storing category names directly in cl_to. This commit updates all queries to join with the linktarget table and use lt_title instead of cl_to.

Changes:

  • Query.php: Updated all category-related queries to join linktarget
    • _addcategories, _articlecategory, _category, _notcategory
    • _ordermethod (category case), getSubcategories
    • buildAndSelect (categories goal)
  • Article.php: Updated to read lt_title from query results
  • Parse.php: Updated categories goal to use lt_title
  • CreateView.php: Updated dpl_clview VIEW to use linktarget
  • ArticleTest.php: Updated test fixtures to use lt_title

All joins use the pattern: cl_target_id = lt_id AND lt_namespace = NS_CATEGORY

🤖 Generated with Claude Code

Co-Authored-By: Claude [email protected]

hexmode avatar Jan 04 '26 02:01 hexmode