Hi - im using the DPL extension to display multiple categories on a page, is there a way to get the count of total articles in 2 or 3 categories?
e.g.
category 1 = 10 articles category 2 = 5 articles
category1 + category2 with logical "and" = 10 category1 + category2 with logical "or" = 15
regards and TIA'
zham
Here is an example DPL query that works for me:
{{#dpl: category = Servers {{!}} Meetings |resultsheader = %TOTALPAGES% |format = ,,, }}
You must also create an article called Template:! Containing: |
Because we want to count the total we use logical or (|) here. That way we get the superset and not the intersection as we would get with logical and (&).
The format parameter is important because we don't want to see any results, just count them.
Rob
On 21/03/2009, at 10:10 PM, zham rock wrote:
Hi - im using the DPL extension to display multiple categories on a page, is there a way to get the count of total articles in 2 or 3 categories?
e.g.
category 1 = 10 articles category 2 = 5 articles
category1 + category2 with logical "and" = 10 category1 + category2 with logical "or" = 15
regards and TIA'
zham _______________________________________________ MediaWiki-l mailing list MediaWiki-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
mediawiki-l@lists.wikimedia.org