Амодуль:Format link/doc
Внешний вид
Это страница документации Амодуль:Format link.
formatPages
[акод аредакциазура]mFormatLink.formatPages(options, pages)
This derived function is useful for lists that format many links. It formats an array of pages using the _formatLink function, and returns the result as an array. Options in the options table are applied, and use the same names as the options for _formatLink.
- Example
mFormatLink.formatPages({categorizeMissing = 'Example'}, {'Foo#Bar', 'Nonexistent page'})→{'[[:Foo#Bar|Foo § Bar]]', '[[:Nonexistent page]][[Category:Example]]'}
Errors
[акод аредакциазура]If _formatLink is used and neither a link nor a target argument is provided, then the module will produce an error message instead of its usual output, as it cannot then produce valid output.
You can solve this error by providing appropriate parameters to _formatLink, or you may want to ensure that a more descriptive error is provided by a downstream template or module when it would otherwise call _formatLink with inadequate arguments.