Extension:TextExtracts/ru

The TextExtracts extension provides an API which allows retrieval of plain-text or limited HTML (HTML with content for some CSS classes removed) extracts of page content.

Configuration settings

 * is an array of &lt;tag>, &lt;tag>.class, .&lt;class>, and #&lt;id> which will be excluded from extraction.
 * For example,  removes indented text, often used for non-templated hatnotes that are not desired in summaries.
 * extension.json defines the defaults, of which the class "noexcerpt" is one - this may be added to any template to exclude it.
 * defines whether TextExtracts should provide its extracts to the Opensearch API module. The default is.

Caveats
There are various things to be aware of when using the API

It does not work for HTML extracts and there are many edge cases for which it doesn't exist. For example "Arm. gen. Ing. John Smith was a soldier." will be treated as 4 sentences. We do not plan to fix this.
 * We do not recommend the usage of `exsentences`.
 * Inline images are stripped from the response (even in HTML mode). This means if you are using the Math extension and using formulae in your lead section they may not appear in the summary output.
 * In HTML mode we cannot guarantee well formed HTML. Resulting HTML may be invalid or malformed.
 * In plaintext mode:
 * citations may not be stripped (see T197266)
 * if a paragraph ends with an HTML tag e.g. ref tag, new lines may be dropped (see T201946),
 * new lines may be dropped after lists T208132

How can I remove content from a page preview/extract?
TextExtracts will strip any element that is marked with the class. This is provided by the configuration variable (which also defines ).

См. также

 * Page Content Service
 * Page Content Service