Related to article (example): Difference between revisions
Content added Content deleted
imported>FrozenPlum m (flag for later cleanup) |
imported>FrozenPlum (remove tempnote as openreferences was fixed in v3.5.0, and fix examples) |
||
Line 1: | Line 1: | ||
{{DPL manual|section=Examples|subsection=Related to article}} |
{{DPL manual|section=Examples|subsection=Related to article}} |
||
==List pages linked from |
==List pages linked from article== |
||
The following example would produce a list of pages linked from [[Manual]] article. |
|||
<pre> |
<pre> |
||
{{#dpl: |
{{#dpl: |
||
⚫ | |||
|openreferences=yes |
|||
|ordermethod=none |
|ordermethod=none |
||
⚫ | |||
|count=5 |
|count=5 |
||
}} |
}} |
||
</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>. |
|||
'''Result:'''<br> |
'''Result:'''<br> |
||
{{#dpl: |
{{#dpl: |
||
⚫ | |||
|openreferences=yes |
|||
|ordermethod=none |
|ordermethod=none |
||
⚫ | |||
|count=5 |
|count=5 |
||
}} |
}} |
||
⚫ | |||
=== Notes === |
|||
*Use <code>|openreferences=yes</code> to include links to non-existing pages (red links). In the example above, if <code>|openreferences=yes</code> were specified, any red links that might appear on [[Extension:DPL3/Manual]] would be listed in the output along with existing pages. |
|||
{{tempnote}} |
|||
⚫ | |||
⚫ | |||
<pre> |
<pre> |
||
{{#dpl: |
{{#dpl: |
||
|usedby= |
|usedby=Apple |
||
|count=5 |
|count=5 |
||
}} |
}} |
||
</pre> |
</pre> |
||
⚫ | |||
'''Result:'''<br> |
'''Result:'''<br> |
||
{{#dpl: |
{{#dpl: |
||
|usedby= |
|usedby=Apple |
||
|count=5 |
|count=5 |
||
}} |
}} |
||
== == |
== == |
||
Produces a list of articles whose title contains the word "Main" and includes the categories for each page. |
|||
<pre> |
<pre> |
||
{{#dpl: |
{{#dpl: |
||
|titlematch=% |
|titlematch=%Main% |
||
|addcategories=true |
|addcategories=true |
||
}} |
}} |
||
Line 50: | Line 46: | ||
'''Result:'''<br> |
'''Result:'''<br> |
||
{{#dpl: |
{{#dpl: |
||
|titlematch=% |
|titlematch=%Main% |
||
|addcategories=true |
|addcategories=true |
||
|count=5 |
|count=5 |
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
}}