Jump to content

Template:Attribution: Difference between revisions

From Joepedia
No edit summary
No edit summary
 
(15 intermediate revisions by the same user not shown)
Line 1: Line 1:
<includeonly>{{#if:{{{categorise|}}}|[[Category:By {{{1}}}]]}}</includeonly>by <span style="display: flex;"><span style="margin-right: 0.5em;" class="inline-img circular">{{#ifexist:{{{1}}}/Avatar|{{:{{{1}}}/Avatar}}|{{#ifexist:File:{{{1}}}.png|[[File:{{{1}}}.png||25px|link={{{1}}}|class=circular]]}}</span>&nbsp;}}[[{{{1}}}]]</span><noinclude>
<includeonly>{{#if:{{{categorise|}}}|[[Category:By {{DisplayName|{{{1}}}|no_link=1}}]]}}by {{Person|{{{1}}}}}</includeonly><noinclude>
== Example ==
E.g:  
  <nowiki>{{Attribution|Joseph Anderson}}</nowiki>
{{Attribution|Joseph Anderson}}
 
Using
  <nowiki>{{Attribution|Joseph Anderson|categorise=true}}</nowiki>
Would place this article into a category "By Joseph Anderson", making it easy to find works by them.
 
== Template Data ==
<templatedata>
<templatedata>
{
{
"params": {
"params": {
"1": {
"1": {
"aliases": [
"by",
"creator",
"name",
"artist"
],
"label": "Creator",
"label": "Creator",
"description": "The name of the person who made the thing being attributed.",
"description": "The name of the page for the person who made the thing being attributed.",
"type": "string",
"type": "wiki-page-name",
"required": true
"required": true
},
},
"categorise": {
"categorise": {
"label": "Categorise",
"label": "Categorise",
"description": "If this should add the page to the \"By {{{1}}}\" category, use if this is the page for the work being discussed.",
"description": "If this should add the page to the “By {{{1}}}category, use if this is the page for the work being discussed.",
"type": "boolean",
"type": "boolean",
"default": "false",
"default": "0"
"aliases": [
"category",
"categorize"
]
}
}
},
},
"description": "Attribute something to someone.",
"description": "Attribute something to someone, using the optional “categorise” flag lets you easily add categories for things people have made.",
"paramOrder": [
"paramOrder": [
"1",
"1",

Latest revision as of 22:38, 6 March 2025

Example

E.g:

 {{Attribution|Joseph Anderson}}

by Joseph Anderson

Using

 {{Attribution|Joseph Anderson|categorise=true}}

Would place this article into a category "By Joseph Anderson", making it easy to find works by them.

Template Data

Attribute something to someone, using the optional “categorise” flag lets you easily add categories for things people have made.

Template parameters[Edit template data]

This template prefers inline formatting of parameters.

ParameterDescriptionTypeStatus
Creator1

The name of the page for the person who made the thing being attributed.

Page namerequired
Categorisecategorise

If this should add the page to the “By {{{1}}}” category, use if this is the page for the work being discussed.

Default
0
Booleanoptional