Difference between revisions of "Talk:Manual"
From FollowTheScore
(→Installation issues) |
(→Installation issues) |
||
Line 26: | Line 26: | ||
==Installation issues== | ==Installation issues== | ||
+ | ===Problem=== | ||
Great extension that I was using on a previous version of mediawiki. Now have moved my site and upgraded to: | Great extension that I was using on a previous version of mediawiki. Now have moved my site and upgraded to: | ||
*Mediawiki 1.9.0 | *Mediawiki 1.9.0 | ||
Line 57: | Line 58: | ||
Frank --[[User:58.106.107.217|58.106.107.217]] 04:01, 18 February 2007 (CET) | Frank --[[User:58.106.107.217|58.106.107.217]] 04:01, 18 February 2007 (CET) | ||
+ | |||
+ | === Answer === | ||
+ | Sorry if the chapter on installation has not been clear enough: | ||
+ | # There are '''three source files''' which you must download and put into a common directory named ''DynamicPageList''. So you end up with | ||
+ | #* ''yourwiki'' /extensions/DynamicPageList/DynamicPageList2.php | ||
+ | #* ''yourwiki'' /extensions/DynamicPageList/DynamicPageList2Include.php | ||
+ | #* ''yourwiki'' /extensions/DynamicPageList/DynamicPageList2.i18n.php | ||
+ | # You must invoke DPL from your LocalSettings.php with<br><code>require_once("extensions/DynamicPageList/DynamicPageList2.php"); </code> | ||
+ | # You should run the database statement which creates an additional MySQL view if you want to use DPL statements which refer to uncategorized pages. Many installations work well without that and you can postpone this step until you really need it. If DPL cannot execute a DPL statement without that vies it will issue a warning. | ||
+ | # It is '''not necessary''' to install LabeledSectionTransclusion (lst.php, lsth.php); it is of no harm either. DPL comes with a slightly modified built-in version of that extension. | ||
+ | # There is a special feature in DPL which needs another extension: If you use page inclusion and want to use images as link symbols for the original source you must install the [[meta:LinkedImage LinkedImage extension]]. For details see there. | ||
+ | -- Algorithmix [[User:84.58.222.19|84.58.222.19]] 07:54, 18 February 2007 (CET) |
Revision as of 07:54, 18 February 2007
From the manual:
- To include variables which are used in a template call, specify the original template name within single curly braces and add a suffix; the template name including the suffix will be called instead of the original template and the result will contain just the output of your alternate template:
includepage = {template1}suffix1,{template1}suffix2,{template2}suffix3,....
Does this mean the following?
- If page A is in the resulting set of pages, and A contains a call {{B|C}}, then includepage={B}D produces the result of {{BD|C}}.
That does not seem to work. What is meant? Can an example be given?--Patrick 17:09, 17 February 2007 (CET)
- Your interpretation is exactly right. The template call to "B" is replaced by a call to "BD" with the same arguments, and you will get the result of the expansion of BD being called with the original parameters. Have a look at Example 2;
<DPL> category=African Union member states includepage={Infobox Country or territory} dpl mode=userformat addpagecounter=true listseparators=\n{|class=sortablewikitable id=123 \n!Country \n!Area \n!Population \n|#hits\n|-,\n|-\n|[[#%PAGE%|%PAGE%]]\n,\n|align=right|%COUNT%\n,\n|} secseparators=,\n|,, </DPL>
- The Template Template:Infobox Country or territory dpl is used to create the entries in the small table. Note that the space character between "territory" and "dpl" comes from the way the DPL statement was written and is significant. Maybe someting like "includepage={Infobox Country or territory}.dpl" would have been more instructive.
- Can you please post the code snippet with which you tried? Maybe we can find the error and improve documentation based on the kind of error you made. -- Gero 20:17, 17 February 2007 (CET)
Installation issues
Problem
Great extension that I was using on a previous version of mediawiki. Now have moved my site and upgraded to:
- Mediawiki 1.9.0
- MySQL 4.1
- DPL 0.9x
and I can't get it to work at all.
- I downloaded and copied DynamicPageList2.php from the manual page into extensions.
- added require_once("extensions/DynamicPageList2.php");
No good.. test page of
<DPL> category = CNS </DPL>just renders
<DPL> category = CNS </DPL> as text.
tried to add Labeled Section Transclusion files with changes to localsetting.php
require_once("extensions/DynamicPageList2.php"); require_once("extensions/lst.php"); require_once("extensions/lsth.php"); require_once("extensions/compat.php");
Still no good.
I am not sure what else needs to be done...
test page for my site is here: [1]
Frank --58.106.107.217 04:01, 18 February 2007 (CET)
Answer
Sorry if the chapter on installation has not been clear enough:
- There are three source files which you must download and put into a common directory named DynamicPageList. So you end up with
- yourwiki /extensions/DynamicPageList/DynamicPageList2.php
- yourwiki /extensions/DynamicPageList/DynamicPageList2Include.php
- yourwiki /extensions/DynamicPageList/DynamicPageList2.i18n.php
- You must invoke DPL from your LocalSettings.php with
require_once("extensions/DynamicPageList/DynamicPageList2.php");
- You should run the database statement which creates an additional MySQL view if you want to use DPL statements which refer to uncategorized pages. Many installations work well without that and you can postpone this step until you really need it. If DPL cannot execute a DPL statement without that vies it will issue a warning.
- It is not necessary to install LabeledSectionTransclusion (lst.php, lsth.php); it is of no harm either. DPL comes with a slightly modified built-in version of that extension.
- There is a special feature in DPL which needs another extension: If you use page inclusion and want to use images as link symbols for the original source you must install the meta:LinkedImage LinkedImage extension. For details see there.
-- Algorithmix 84.58.222.19 07:54, 18 February 2007 (CET)