Jump to content

Manual talk:$wgTitle

Add topic
From mediawiki.org
Latest comment: 12 years ago by Bawolff in topic What to use instead?

What to use instead?

[edit]

Guys, what should I use instead of so useful $wgTitle in my extensions? I think the documentation here is need to be improved :) --Katkov Yury 11:44, 17 October 2011 (UTC)Reply

if I understood correctly, you should use $context->getTitle(). Cf. Manual:RequestContext --Kipmaster 18:35, 11 December 2011 (UTC)Reply
What specifically you should use depends on your code, but generally what kipmastser said (What is a ContextSource can sometimes be unclear though). Bawolff 19:27, 11 December 2011 (UTC)Reply