Topic on Project:Support desk

Jump to navigation Jump to search

How to edit the footer menu when working with default skins?

11 (talkcontribs)

I have an Hebrew MediaWiki 1.34.0 website with the Timeless responsive skin.

I desire to edit the footer menu in various ways: Delete some default links (not with CSS/JS), add some links, etc.

How can this be done (again, not from CSS/JS) and without installing any extension?

Thanks in advance,

Ammarpad (talkcontribs) (talkcontribs)


I have read that page; I misunderstand the following:

  • Where is extension.json in which I should add SkinAddFooterLinks if no extension is used for removal?
  • Why was it written in the docs:
Called from: File(s): SkinTemplate.php

If we can call the hook from another file, such as LocalSettings.php (which is what I originally aimed to do)?

TiltedCerebellum (talkcontribs)

See the answer above (as it is basically the same question, just a duplicate question.. If you don't want an extension you have to learn how to use hooks and write the code necessary for what you want to accomplish): Topic:Vr0seh3pasonm7xk (talkcontribs)

@TiltedCerebellum based on your comments and some reading in Manual:Hooks I now regard "Hooks" as a pseudo-extension because while there isn't an extension with that name, our hook pseudo-extensions are declared at extensions.json

Furthermore, I think that hooks in MediaWiki are a "custom reaction to a given contextualized condition".

TiltedCerebellum (talkcontribs)

Yes, hooks are made to extend MediaWiki functionality as extensions are for, extension writers use them (as do users) to extend what is normally possible in MediaWiki out of the box. If you don't want to do something more than is possible out of the box with MediaWiki, then hooks/extending are probably not for you. Can I ask why you are adverse to extensions? Mediawiki comes bundled with many extensions that are fairly necessary to do a lot of useful things... such as parser functions to do math and calculate things to help create advanced infoboxes etc. Inputboxes, and lots of other extensions. Especially the WikiEditor extension that provides the editing toolbar when editing. Unless you enabled none of them on install, you probably already have extensions running.

It would be nice if there was a footer page to edit like there is for the sidebar, but unfortunately there isn't. Extending either through an extension (that uses hooks) or through a simple user-written hook would be required. (talkcontribs)

@TiltedCerebellum I avoid using extensions due to a minimalist long-term approach; from my experience with working with various CMSs through the years, I have found that minimalist approaches make my Bash-written upgrade scripts much easier to maintain.

Because, currently, I have only one extension in my website and prefer to keep it this way, I think I would customize the footer menu by a hook (I am not sure if it should be one hook for all links or one hook for each link). (talkcontribs)

@TiltedCerebellum also, I think, from a modular standpoint, that I should have asked two different questions:

  1. How to delete a default footer link in MediaWiki
  2. How to create a default footer link in MediaWiki

I am sure we will both agree that deleting is easier than creating in that case, and to read a hook code example to do do so would make my life easier when trying to create a new link (I need to both delete and create):

Someone might want to reply here with a code example that others and myself could learn from.

TiltedCerebellum (talkcontribs)

Please don't presume what I would agree on. Good luck to you with your approach though. (talkcontribs)

@TiltedCerebellum generally I don't take that approach and I take back what I said above ("I am sure we will both agree...").

In no way have I meant o disrespect you.

I hope to get some more help from you on this matter.

TiltedCerebellum (talkcontribs)
Reply to "How to edit the footer menu when working with default skins?"