Шаблон:Purge
10px⧼purge-purge⧽
Note to editors: Please don't categorize this template by editing it directly. Instead, place the category in its documentation page, in its "includeonly" section.
This template has a sandbox (Редагувати) for editors to experiment.
Inserts a link that rebuilds the current page without using the cache. The link is displayed in the user's interface language, regardless of the page's content language. This link appears at the top of {{Languages}} and {{Documentation}}, which together appear on virtually every page of the wiki.
Usage[ред.]
{{purge}}
Parameters:
- |{{#sub:page|0|{{#pos:page|=}}}} = {{#sub:page|Помилка виразу: незрозумілий розділовий знак «{»}}
- (Optional) The page that is purged when clicking the inserted link. If this parameter is omitted, the default value is the current page.
The |{{#sub:lang|0|{{#pos:lang|=}}}} = {{#sub:lang|Помилка виразу: незрозумілий розділовий знак «{»}} parameter is no longer supported. The link is always displayed in the user's interface language.
Examples[ред.]
- {{#invoke:Demo|inline}}
- Purges the current page.
- {{#invoke:Demo|inline}}
- Purges the specified page.
Rationale[ред.]
For efficiency in service, MediaWiki caches pages. Depending on the exact sequence of actions editors follow, one may view an out-of-date version of a given page. This happens most often on heavily-edited pages and on pages which contain an transcluded templates.
{{Purge}} adds to any page a link that, when clicked, not only reloads the page, but clears the server cache, forcing the page to be completely rendered "from scratch". This is not a one-time solution; generally, editing a page is itself sufficient to purge cache. Rather, it is a measure taken in anticipation of the frequent need to purge.
<templatedata> { "params": { "page": { "label": "Page title", "description": "The page that is purged when clicking the inserted link. If this parameter is omitted, the default value is the current page.", "example": "Main Page", "type": "wiki-page-name" } }, "description": "Inserts a link that rebuilds the current page without using the cache. The link is displayed in the user's interface language, regardless of the page's content language.", "format": "inline" } </templatedata>