If $wgRelatedArticlesShowInFooter is false, then we'll still test
whether or not the page is a disambiguation page with the Disambiguator
extension. Unfortunately, DisambiguatorHooks::isDisambiguationPage hits
the DB.
Order the tests in RelatedArticles\FooterHooks::onBeforePageDisplay from
least expensive to most expensive so that the DB is queried only when it
must be.
This version of the patch takes into account namespace.
Bug: T127068
Bug: T144409
Change-Id: Ie6ddaa4e9bd8326c8b84dc400b78e9a4f4d0d78d
We forgot how namespaces work:
Catchable fatal error: Argument 1 passed to RelatedArticles\FooterHooks::isDisambiguationPage() must be an instance of RelatedArticles\Title, Title given in /srv/mediawiki/php-master/extensions/RelatedArticles/includes/FooterHooks.php on line 48
This reverts commit 9ede8913c7.
Change-Id: If0f1481854815c12613771041685c7837a95ec65
If $wgRelatedArticlesShowInFooter is false, then we'll still test
whether or not the page is a disambiguation page with the Disambiguator
extension. Unfortunately, DisambiguatorHooks::isDisambiguationPage hits
the DB.
Order the tests in RelatedArticles\FooterHooks::onBeforePageDisplay from
least expensive to most expensive so that the DB is queried only when it
must be.
Bug: T127068
Change-Id: Ie3e7e410026cf354d831ae3c2134cfc0957eb8db
Uses DisambiguatorHooks to prevent related pages module addition on
disambiguation pages.
Bug: T127068
Change-Id: I166712d7e5df26ad00c725f3e4fe23ec074b3329
* Load skin specific styles only in that skin;
* Vector styles are default for all skins unless overwritten;
* Allow monobook styles to inherit from vector styles;
* Do not load visual editor related rules in minerva;
* Remove an unused CSS rule.
Bug: T126149
Change-Id: I1e657de7a45fb4812c42ca7b99624b585dc4b7dd
Changes:
* Rename $wgRelatedArticlesShowReadMore to $wgRelatedArticlesShowInFooter
* Add $wgRelatedArticlesShowInSidebar, which is truthy by default, and
short circuit the SkinBuildSidebar and SkinTemplateToolboxEnd hook
handlers if it is falsy
Bug: T119926
Change-Id: Idf04bf3221ba44d7b898160764fbd6ba83561abb
There are two positions where the list of related articles is rendered:
the sidebar, and the the footer. Move the hook handlers related to
rendering the former to RelatedArticles\SidebarHooks and those related
to rendering the latter to RelatedArticles\FooterHooks.
Change-Id: Idde57905d828e63309bfdc360a3a09e64e291304
2015-12-02 11:10:04 +00:00
Renamed from includes/ReadMoreHooks.php (Browse further)