# Linker This plugin allows to define custom linker commands in analogy to the builtin `{filename}`, `{attach}`, `{category}`, `{tag}`, `{author}`, and `{index}` syntax. ## Provided commands (each of which in its own submodule) ### `{mailto}` **Purpose:** Helps to create `mailto:` links with javascript (JS) on top of a non-JS fallback. * **How the HTML code is replaced step by step** * your code in a content file (page or article): ``` Send me a mail ``` * plugin replacement (after computing `'jroznfgre' = rot_13('webmaster')`): ``` Send me a mail ``` * result of a JS-powered transform (which you could add): ``` Send me a mail ``` * As a fallback for users without JS, the static page `mailto/jroznfgre/index.html` is generated using the template `mailto_fallback`. * **Usage instruction** * activate nested `{mailto}` plugin using ``` PLUGINS = ['linker.mailto'] ``` * provide the `mailto_fallback` template (accessing `mailto` which is injected into the template) * optionally, add some JS to improve the user experience as sketched above ## Other included submodules ### `content_objects` This plugin collects all `pelican.contents.Content` instances in a `set` which can be accessed using `context['content_objects']`.