Topic on Manual talk:FAQ

Section 'How do I add/remove tabs throughout my wiki?' is outdated

4
Cycloneblaze (talkcontribs)

The given code doesn't work with an error saying the function wfMsgForContent() is unknown. Per here, the function seems to have been removed - the recommended is simply to remove the function. I would edit the page myself to add a corrected code snippet, but I'm no great shake at PHP so I wouldn't like to provide something else that's wrong :b

Ciencia Al Poder (talkcontribs)

The function that's mentioned in that thead is wfLoadExtensionMessages, not wfMsgForContent!

   wfMsgForContent( 'key' );

must be replaced by

   wfMessage( 'key' )->inContentLanguage()->text();
Ciencia Al Poder (talkcontribs)

I've changed the code to reflect that. But I haven't tested if it works

Cycloneblaze (talkcontribs)

The extension gives no errors and now adds the link to the main page, like it should. It doesn't remove the 'Discussion' tab but that's a different issue I think.

Reply to "Section 'How do I add/remove tabs throughout my wiki?' is outdated"