Pomoc API MediaWiki
To jest automatycznie wygenerowana strona dokumentacji API MediaWiki.
Dokumentacja i przykłady: https://www.mediawiki.org/wiki/Special:MyLanguage/API:Main_page
action=setpagelanguage
(main | setpagelanguage)
- Ten moduł wymaga praw odczytu.
- Ten moduł wymaga praw zapisu.
- Ten moduł akceptuje tylko żądania POST.
- Źródło: MediaWiki
- Licencja: GPL-2.0-or-later
Zmień język strony.
Zmiana języka strony nie jest dozwolona na tej wiki.
Włącz $wgPageLanguageUseDB by użyć tej akcji.
Parametry:
Other general parameters are available.
- title
Title of the page whose language you wish to change. Cannot be used together with pageid.
- pageid
Page ID of the page whose language you wish to change. Cannot be used together with title.
- Typ: liczba całkowita
- lang
Language code of the language to change the page to. Use default to reset the page to the wiki's default content language.
- Ten parametr jest wymagany.
- Jedna z następujących wartości: default, en, en-gb, pl
- reason
Powód zmiany.
Change tags to apply to the log entry resulting from this action.
- Wartości (oddziel za pomocą | lub alternatywy):
- token
Token „csrf” pobrany z action=query&meta=tokens
- Ten parametr jest wymagany.
Przykłady:
- Change the language of the page Strona główna to Basque.
- api.php?action=setpagelanguage&title=Strona%20g%C5%82%C3%B3wna&lang=eu&token=123ABC [otwórz w brudnopisie]
- Change the language of the page with ID 123 to the wiki's default content language.
- api.php?action=setpagelanguage&pageid=123&lang=default&token=123ABC [otwórz w brudnopisie]