Vorlage:ThisWay: Unterschied zwischen den Versionen
Zur Navigation springen
Zur Suche springen
(57 dazwischenliegende Versionen desselben Benutzers werden nicht angezeigt) | |||
Zeile 1: | Zeile 1: | ||
− | <! | + | <!-- |
VARIABLE | VARIABLE | ||
+ | -->{{#vardefine: defaultlink | ||
+ | | {{#ifeq: {{NAMESPACENUMBER}}| 0 | ||
+ | | {{BASEPAGENAME}} | ||
+ | | {{NAMESPACE}}:{{BASEPAGENAME}} | ||
+ | }} }}<!-- | ||
-->{{#vardefine: link | -->{{#vardefine: link | ||
− | + | | {{#if: {{{1|}}} | {{{1|}}} | {{#var:defaultlink}} }} | |
− | |||
− | | {{ | ||
}}<!-- | }}<!-- | ||
+ | -->{{#vardefine: link_markup | ||
+ | | {{#if: {{{1|}}} | ||
+ | | [[{{{1|}}}|<span>Weiter zu:</span> {{#show: {{{1|}}}|?hat_titel}} {{#fas:angle-double-right}}]] | ||
+ | | [[{{#var:link}}|{{#fas:angle-double-left}} <span>Zurück zu:</span> {{#show: {{#var:link}}|?hat_titel}}]] | ||
+ | }} }}<!-- | ||
-->{{#vardefine: class | -->{{#vardefine: class | ||
− | | {{#if: {{{1|}}}||class=zurueck}} }}<!-- | + | | {{#if: {{{1|}}}| title='zum nächsten Thema' class='textbox_body' |
− | -->{{#vardefine: | + | | class='zurueck textbox_body' title='zurück zum Hauptartikel'}} }}<!-- |
− | | {{# | + | -->{{#vardefine: shorttitle |
− | + | | {{#titleparts:{{PAGENAME}}| | -1}} | |
− | |||
− | |||
− | |||
− | |||
− | |||
}}<!-- | }}<!-- | ||
SCHREIBEN | SCHREIBEN | ||
− | --> | + | -->{{#if: {{{noway|}}} |<!-- do nothing--> |
− | --> | + | |<div {{#var:class}} id=thisway>{{#var:link_markup}}</div> |
− | | | + | }}<!-- |
− | + | ||
− | </div> | + | --><includeonly>{{#css: |
− | + | #siteNotice .crumbs { | |
− | + | display: none; | |
+ | } | ||
}}<!-- | }}<!-- | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | + | KATEGORIEN und Attribute | |
− | |||
− | |||
− | + | -->{{#if: {{{nocat|}}} | <!-- do nothing --> | |
+ | | [[Kategorie:Artikel]] <!-- | ||
+ | -->{{#if: {{{1|}}} | ||
+ | | {{#set: thisway links to={{#var:link}} | ||
+ | | written_by={{#if: {{{autor|}}}| {{{autor|}}} | Bernhard Scheid}} | ||
+ | }} | ||
+ | }}<!-- | ||
+ | -->{{#set: | ||
+ | {{#switch: {{NAMESPACENUMBER}} | ||
+ | | 0= is_mainspace_article | ||
+ | | 4= is_metalog_article | ||
+ | | 12= is help article | ||
+ | }}={{#var:shorttitle}} | ||
+ | }} | ||
+ | }}</includeonly> | ||
+ | <noinclude> | ||
+ | === Code === | ||
− | + | <pre> | |
− | + | {{ThisWay | |
− | + | | | |
− | + | | nocat= | |
− | | | + | | noway= |
− | + | | autor= <!-- nicht BS --> | |
− | --> | + | }} </pre> |
− | |||
− | |||
− | </ | ||
− | |||
− | + | <templatedata> | |
− | + | { | |
− | + | "params": { | |
− | + | "1": { | |
− | + | "description": "link adresse", | |
− | + | "type": "string", | |
+ | "autovalue": "Parent-Pagename" | ||
+ | }, | ||
+ | "noway": { | ||
+ | "description": "keinen Link anzeigen", | ||
+ | "type": "boolean", | ||
+ | "autovalue": "0" | ||
+ | }, | ||
+ | "nocat": { | ||
+ | "label": "no category", | ||
+ | "description": "keine Kategorie hinzufügen", | ||
+ | "type": "boolean", | ||
+ | "autovalue": "0" | ||
+ | }, | ||
+ | "autor": { | ||
+ | "description": "Gastautor", | ||
+ | "type": "string" | ||
+ | } | ||
+ | }, | ||
+ | "description": "Fügt Weiter-zu Links am Ende des Artikels ein.", | ||
+ | "format": "block" | ||
+ | } | ||
+ | </templatedata> | ||
</noinclude> | </noinclude> |
Version vom 4. April 2022, 21:27 Uhr
Code
{{ThisWay | | nocat= | noway= | autor= <!-- nicht BS --> }}
Fügt Weiter-zu Links am Ende des Artikels ein.
Parameter | Beschreibung | Typ | Status | |
---|---|---|---|---|
1 | 1 | link adresse
| Zeichenfolge | optional |
Noway | noway | keinen Link anzeigen
| Boolesch | optional |
no category | nocat | keine Kategorie hinzufügen
| Boolesch | optional |
Autor | autor | Gastautor | Zeichenfolge | optional |