Difference between revisions of "Example 2"
(3 intermediate revisions by the same user not shown) | |||
Line 3: | Line 3: | ||
First we create a small table with some figures (taken from template calls of the original pages). We also add some meta data on popularity (hit rates of the articles). | First we create a small table with some figures (taken from template calls of the original pages). We also add some meta data on popularity (hit rates of the articles). | ||
<pre><nowiki> | <pre><nowiki> | ||
− | + | ||
<DPL> | <DPL> | ||
category=African Union member states | category=African Union member states | ||
Line 9: | Line 9: | ||
mode=userformat | mode=userformat | ||
addpagecounter=true | addpagecounter=true | ||
− | listseparators=\n{|class= | + | listseparators=\n{|class="wikitable sortable" \n!Country \n!Area \n!Population \n|#hits\n|-,\n|-\n|[[#%PAGE%|%PAGE%]]\n,\n|align=right|%COUNT%\n,\n|} |
secseparators=\n| | secseparators=\n| | ||
</DPL> | </DPL> | ||
</nowiki></pre> | </nowiki></pre> | ||
− | + | ||
<DPL> | <DPL> | ||
category=African Union member states | category=African Union member states | ||
Line 19: | Line 19: | ||
mode=userformat | mode=userformat | ||
addpagecounter=true | addpagecounter=true | ||
− | listseparators=\n{|class= | + | listseparators=\n{|class="wikitable sortable" \n!Country \n!Area \n!Population \n|#hits\n|-,\n|-\n|[[#%PAGE%|%PAGE%]]\n,\n|align=right|%COUNT%\n,\n|} |
secseparators=\n| | secseparators=\n| | ||
</DPL> | </DPL> | ||
Line 31: | Line 31: | ||
resultsheader=__NOTOC__ __NOEDITSECTION__ | resultsheader=__NOTOC__ __NOEDITSECTION__ | ||
category=African Union member states | category=African Union member states | ||
− | includepage=#History[350 | + | includepage=#History[350],#Culture[800],{Infobox Country or territory} dpl2 |
mode=userformat | mode=userformat | ||
− | listseparators=\n{|class= | + | listseparators=\n{|class="wikitable sortable" \n!Country \n!History \n!Culture \n!Area &<br>Population \n|-,\n|-\n|valign=top|\n=====[[%PAGE%]]=====\n,,\n|} |
secseparators=\n| | secseparators=\n| | ||
</DPL> | </DPL> | ||
Line 41: | Line 41: | ||
resultsheader=__NOTOC__ __NOEDITSECTION__ | resultsheader=__NOTOC__ __NOEDITSECTION__ | ||
category=African Union member states | category=African Union member states | ||
− | includepage=#History[350 | + | includepage=#History[350],#Culture[800],{Infobox Country or territory} dpl2 |
mode=userformat | mode=userformat | ||
− | listseparators=\n{|class= | + | listseparators=\n{|class="wikitable sortable" \n!Country \n!History \n!Culture \n!Area &<br>Population \n|-,\n|-\n|valign=top|\n=====[[%PAGE%]]=====\n,,\n|} |
secseparators=\n| | secseparators=\n| | ||
</DPL> | </DPL> | ||
<references/> | <references/> |
Latest revision as of 20:52, 22 August 2012
This example for the use of DPL is based on a copy of articles from the English wikipedia.
First we create a small table with some figures (taken from template calls of the original pages). We also add some meta data on popularity (hit rates of the articles).
<DPL> category=African Union member states includepage={Infobox Country or territory} dpl mode=userformat addpagecounter=true listseparators=\n{|class="wikitable sortable" \n!Country \n!Area \n!Population \n|#hits\n|-,\n|-\n|[[#%PAGE%|%PAGE%]]\n,\n|align=right|%COUNT%\n,\n|} secseparators=\n| </DPL>
Country | Area | Population | #hits |
---|---|---|---|
Cameroon | 475,442 | 16,323,000 | %COUNT% |
Nigeria | 923,768 | 133,530,0001 | %COUNT% |
Somalia | 637,657 | 8,228,000 | %COUNT% |
Sudan | 2,505,813 | 36,992,490 | %COUNT% |
Note that the country names in the small table link to the corresponding entry in the big table. In the History column of the big table we define a small image to be used as a "..more.." symbol; in the column on Religion we use the default (..→) We cut off contents at a convenient size in both columns. The last column contains some significant figures for each country. Its contents is formated in a separate template which replaces the original template during the creation of the report.
<DPL> resultsheader=__NOTOC__ __NOEDITSECTION__ category=African Union member states includepage=#History[350],#Culture[800],{Infobox Country or territory} dpl2 mode=userformat listseparators=\n{|class="wikitable sortable" \n!Country \n!History \n!Culture \n!Area &<br>Population \n|-,\n|-\n|valign=top|\n=====[[%PAGE%]]=====\n,,\n|} secseparators=\n| </DPL>
Country | History | Culture | Area & Population | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Cameroon |
Pre-colonial periodArchaeological finds show that humankind has ..→ |
Each of Cameroon's ethnic groups has its own unique cultural forms. Typical celebrations include births, deaths, planting, harvesting, and religious events. ..→ |
475,442 km²
| ||||||||||||||||
Nigeria |
More than 2,000 years ago. the Nok people in central Nigeria were producing sculptures. ..→ |
Literature
Nigeria has a rich literary history, both prior to British imperialism and after, as Nigerians have authored several works of post-colonial literature in the English language. The second African Nobel Laureate, Wole Soyinka is Nigeria's best-known writer and playwright. Other Nigerian writers and poets who are well known on the international stage include Chinua Achebe, John Pepper Clark, Ben Okri, Sonny Oti and Ken Saro Wiwa who was executed in ..→ |
923,768 km²
| ||||||||||||||||
Somalia |
Pre-colonial timesSomalia has been continuously inhabited by numerous and varied ethnic groups, some of Italian or Yemenite ancestry, but the majority are Somalis, for the last 2,500 years. In late antiquity, the northern part of ..→ |
|
637,657 km²
| ||||||||||||||||
Sudan |
Early history of Sudan |
Sudan's largest Christian denominations are the Roman Catholic Church, the Episcopal Church of the Sudan, the Presbyterian Church in the Sudan and the Coptic Orthodox Church. |
2,505,813 km²
|
<references/>