Related to article (example): Difference between revisions
Content added Content deleted
m (→IGNORE - DEBUG TESTING BY DEVELOPERS. THIS PAGE HAS AN ISSUE.: clean up, replaced: [[zh:Extension::{{subst:BASEPAGENAME}}]] → [[zh:扩展:{{subst:BASEPAGENAME}}]]) |
imported>FrozenPlum (remove tempnote as openreferences was fixed in v3.5.0, and fix examples) |
||
(6 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
{{DPL manual|section=Examples|subsection=Related to article}} |
{{DPL manual|section=Examples|subsection=Related to article}} |
||
==List |
==List pages linked from article== |
||
<pre> |
|||
The following example |
|||
{{#dpl: |
|||
|linksfrom=Apple |
|||
<pre><nowiki>{{#dpl: |
|||
format=,[[%PAGE%]],<br/> |
|||
|openreferences=yes |
|openreferences=yes |
||
|ordermethod=none |
|ordermethod=none |
||
|count=5 |
|||
|linksfrom=Extension:DPL3/Manual |
|||
}} |
|||
}}</nowiki></pre> |
|||
</pre> |
|||
Produces a list of pages linked from the [[Apple]] article, limited to 5 results, including links to non-existing pages (if any) due to the use of <code>openreferences=yes</code>. |
|||
Would produce a list of articles that link to Extension:DPL3/Manual |
|||
'''Result:'''<br> |
|||
{{#dpl: |
{{#dpl: |
||
|linksfrom=Apple |
|||
format=,[[%PAGE%]],<br/> |
|||
|openreferences=yes |
|openreferences=yes |
||
|ordermethod=none |
|ordermethod=none |
||
|count=5 |
|||
|linksfrom=Extension:DPL3/Manual |
|||
}} |
}} |
||
==List templates |
==List templates used by an article== |
||
<pre> |
|||
The following example |
|||
{{#dpl: |
|||
|usedby=Apple |
|||
|count=5 |
|||
}} |
|||
</pre> |
|||
⚫ | |||
'''Result:'''<br> |
|||
<pre><nowiki>{{#dpl: |
|||
{{#dpl: |
|||
format=,[[%PAGE%]],<br/> |
|||
|usedby= |
|usedby=Apple |
||
|count=5 |
|||
}}</nowiki></pre> |
|||
}} |
|||
⚫ | |||
==IGNORE - DEBUG TESTING BY DEVELOPERS. THIS PAGE HAS AN ISSUE.== |
|||
== == |
|||
Produces a list of articles whose title contains the word "Main" and includes the categories for each page. |
|||
<pre> |
|||
{{#dpl: |
{{#dpl: |
||
titlematch= |
|titlematch=%Main% |
||
|addcategories=true |
|addcategories=true |
||
|format=,²{#replace:Category:%CATNAMES%¦²{comma}²¦<br/>Category:}²,<br/> |
|||
}} |
}} |
||
</pre> |
|||
'''Result:'''<br> |
|||
{{#dpl: |
{{#dpl: |
||
|titlematch=%Main% |
|||
mode=userformat |
|||
|addcategories=true |
|||
|format=,[[%PAGE%]],<br/> |
|||
|count=5 |
|||
|escapelinks=true |
|||
|imagecontainer=Extension:DPL3/Manual |
|||
}} |
}} |
||
[[Category:Miscellaneous examples]] |
|||
<!-- Extension prefix in other languages: |
|||
[[de:Erweiterung:{{subst:BASEPAGENAME}}]] |
|||
[[es:Extensión:{{subst:BASEPAGENAME}}]] |
|||
[[fr:Extension:{{subst:BASEPAGENAME}}]] |
|||
[[it:Estensione:{{subst:BASEPAGENAME}}]] |
|||
[[nl:Uitbreiding:{{subst:BASEPAGENAME}}]] |
|||
[[pl:Rozszerzenie:{{subst:BASEPAGENAME}}]] |
|||
[[pt:Extensão:{{subst:BASEPAGENAME}}]] |
|||
[[ru:Расширение:{{subst:BASEPAGENAME}}]] |
|||
[[zh:扩展:{{subst:BASEPAGENAME}}]] |
|||
--> |
Latest revision as of 22:38, 16 January 2023
|
Manual | Examples | Related to article |
List pages linked from article
{{#dpl: |linksfrom=Apple |openreferences=yes |ordermethod=none |count=5 }}
Produces a list of pages linked from the Apple article, limited to 5 results, including links to non-existing pages (if any) due to the use of openreferences=yes
.
Result:
{{#dpl:
|linksfrom=Apple
|openreferences=yes
|ordermethod=none
|count=5
}}
List templates used by an article
{{#dpl: |usedby=Apple |count=5 }}
Produces a list of templates that are used by the Apple article.
Result:
{{#dpl:
|usedby=Apple
|count=5
}}
Produces a list of articles whose title contains the word "Main" and includes the categories for each page.
{{#dpl: |titlematch=%Main% |addcategories=true }}
Result:
{{#dpl:
|titlematch=%Main%
|addcategories=true
|count=5
}}