Extension talk:DynamicPageList (third-party)

Latest comment: 8 months ago by BenyElbis in topic Extension:DynamicPageList (third-party)/10

See also Wikimedia's issue tracking system for some bugs and feature requests for this extension.

Existing entries with feature requests on this page have been moved. --Algorithmix 08:45, 16 February 2007 (UTC)Reply[reply]

2007 edit

Recent Changes edit

For putting recent changes in a given namespace or category on a wiki page, there is also Extension:News -- Duesentrieb 13:00, 17 February 2007 (UTC)Reply[reply]

MediaWiki Version edit

This page says that DPL requires v. 1.7+ of MW, but the DPL wiki says 1.8+. Would be worth changing to whichever one is correct! I tried to install with 1.7 and it didn't work, which was disappointing. --16 November 2007

Conflict with RSSReader Extension edit

I've noted a conflict between the RSSReader Extension and DynamicPageList Extension when both are run on the same page. See Comment on RSS_Reader Extension for details. Any idea why this might be?

--C4duser 15:26, 27 November 2007 (UTC)Reply[reply]

2008 edit

Labeled Transclusion Sections with DPL 1.6.9 edit

We just installed DPL 1.6.9 and noticed that our section transclusions are no longer working.

For example, we have





And it used to work with the previous DPL version which displayed all text in the summary section but with DPL 1.6.9 nothing is being picked up. Any ideas? -alhui 18:01, 11 April 2008 (UTC)Reply[reply]

Add the following after the line with inclusion of the extension in the file LocalSettings.php
$wgParserConf['class'] = 'Parser_OldPP';
This will force the mw-core to use the old parser. Jeblad 15:13, 13 April 2008 (UTC)Reply[reply]
Having same problem and the OldPP hack doesn't seem to solve it. (MW 1.12; DPL 1.6.9; the labeled section extension has been deactivated, and the dpl2include seems to work because the "section" tag is listed in my MW spectial:version page). A page called Test1 with the text
The book is <section begin=title />Cien anos de soledad<section end=title/>
is never transcluded in a page Test2 with the code
Nothing is output. The older version 08:32, 17 January 2008 works perfectly though. --Fxparlant 09:55, 14 July 2008 (UTC)Reply[reply]
Try DPL 1.7.4. It runs on MW 1.12 and 1.13 as you can see on the dpldemo website. If you still have a problem, please demonstarte the effect on that website and we will have a look at it. 09:51, 27 August 2008 (UTC)Reply[reply]

Problem with mediawiki 1.12 edit

It seems that message file cause error on mediawiki 1.12 (see this thread). Could author of this extension make the update for us ? -- phkoech 26 april 2008

The dpldemo website is now running on MW 1.13. All problems should be solved. 09:48, 27 August 2008 (UTC)Reply[reply]

labeled section only edit

How to list only the labeled sections, without the pages not containing the section:


will list the pages of category Book, even if they do not have

<section begin=title />

. The includematch cannot be used, because the include doesn't call the whole section, but only the content of the section tags. Any idea ? --Fxparlant 11:06, 14 July 2008 (UTC)Reply[reply]

Catch a template parameter edit

I am looking for a way to use DPL to catch, not the title of a page, but the parameter of a template:

if a page calls the template {{Temp|param1|param2|param3}}, how to catch the param3 in another page, with a query on the first parameter and the second ?

--Fxparlant 13:08, 7 August 2008 (UTC)Reply[reply]

You can use phantom templates for that purpose. DPL will call the phantom template instead of the original one and pass all parameters to the phantom template in the same way as they were passed to the original template. And within the phantom template you can do whatever you like - which means that you can simply output the third parameter.
See the DPL manual for details. 09:47, 27 August 2008 (UTC)Reply[reply]

New pages edit

Is there a way to get this to only return new pages (the pages in Special:Newpages)? Thanks 12:13, 17 August 2008 (UTC)Reply[reply]

"ordermethod=firstedit" was the parameter I needed --18 August 2008
if you do not have too many updates such as daily or weekly news for which the Extension:News might be worth a try you can find an example and explanations on the steps necessary to update the main page almost automatically using DPL and Extension:Inputbox on the page User_talk:Ob.helm.--Ob.helm 16:51, 11 December 2008 (UTC)Reply[reply]

Mediawiki Version 1.6.9 edit


Is there a way to get DPL running on a Mediawiki 1.6.9 ? If not, why exactly ?

Best regards -- 11:26, 4 September 2008 (UTC)Reply[reply]

download from subversion edit

Can the download used the inclued mediawiki subversion system ? Crochet.david 19:00, 14 September 2008 (UTC)Reply[reply]

Currently the latest version is on the dpldemo page. But this will change in the near future. Mediawiki SVN repository will become the official source for distribution. Algorithmix 09:22, 21 May 2009 (UTC)Reply[reply]

_parameter" data-mw-fallback-anchor="Tweak_to_make_DPL_backward_compatible_with_DynamicPageList2_.3Csuppresserrors.3E_parameter" data-mw-thread-id="h-Tweak_to_make_DPL_backward_compatible_with_DynamicPageList2_<suppresserrors>_par-2008-2008-09-18T13:40:00.000Z">Tweak to make DPL backward compatible with DynamicPageList2 <suppresserrors> parameter edit

I'm one of the admins at ChoralWiki (www.cpdl.org), a free Public Domain scores library, and we use DynamicPageList2 a lot in it with parameter <suppresserrors> set to 'true'. We were doing an upgrade test to the newest version of DynamicPageList and after the upgrade all our DPL queries started showing this warning:

 %DPL-1.7.4-WARNING: Unknown parameter '$0' is ignored. Help: available parameters: suppresserrors.

After a quick research we realized that parameter <suppresserrors> is no longer supported by the new DPL versions. It would be a pain to edit all pages where it appears, so we decided to tweak the DPL code to recognize it and behave as expected. We made the changes below, tested it and it worked fine. So we decided to post it here in case someone else faces the same problem. All one needs to do is to add the following lines in red to file DinamicPageList2.php:

line 682:

        * noresultsheader / footer is some wiki text which will be output (instead of a warning message)
        * if the result set is empty; setting 'noresultsheader' to something like ' ' will suppress
        * the warning about empty result set.
       'suppresserrors'       => array('default' => 'false', 'true', 'no', 'yes', '0', '1', 'off', 'on'), 
       'noresultsheader'      => array('default' => ''),
       'noresultsfooter'      => array('default' => ''),

line 1157:

       $bSuppressErrors  = self::argBoolean(self::$options['suppresserrors']['default']);
       $sResultsHeader   = self::$options['resultsheader']['default'];
       $sResultsFooter   = self::$options['resultsfooter']['default'];

line 2095:

               case 'noresultsheader':
                   $sNoResultsHeader = $sArg;
               case 'suppresserrors':
                   if( in_array($sArg, self::$options['suppresserrors'])) {
                       $bSuppressErrors = self::argBoolean($sArg);
                       if( $bSuppressErrors )
                           $sNoResultsHeader = ' ';
                       $output .= $logger->msgWrongParam('suppresserrors', $sArg);
               case 'noresultsfooter':
                   $sNoResultsFooter = $sArg;

After the change, if <suppresserrors=true> is used in the query and 0 pages are returned, it won't show any warning message; if <noresultsheader='text'> is also used, it will show the 'text' supplied. Capmo 13:40, 18 September 2008 (UTC)Reply[reply]

Since release 1.7.5 suppresserrors is part of the official DPL distribution. Algorithmix 09:20, 21 May 2009 (UTC)Reply[reply]

Licence edit

http://semeb.com/dpldemo/index.php?title=Main_Page says that "All extensions are under GPL license". So this page could be updated regarding the license.

Yes, has been done. Algorithmix 09:23, 21 May 2009 (UTC)Reply[reply]

2009 edit

Index (List of index-terms) for a book edit

I am experienced in editing wikipedia-articles. Now I want to use mediawiki on my server to write a book (around 1.000 articles). I want to mark index-terms in articles and have one page with a sorted index. The book will exist of 1.000 articles. So it is no problem to generate the article dynamicaly when I will open the index. Is DPL the right extension to do the job?

How to mark the index-terms in articles? Which <dpl></dpl> -code do I need?

Or is there a better solution than DPL? Regards, jan-- 23:55, 13 January 2009 (UTC)Reply[reply]

I made a beginning:

I have a template template:Index and call it in articles with with


For the output of the whole Index I have an article with:


It works!

How can I get an output in an alphabeticle order like this?

..... articletitle 1
..... articletitle 2
..... articletitle 3
..... articletitle ...

..... articletitle 4
..... articletitle 5
..... articletitle 6
..... articletitle 7
..... articletitle ...

...... ...

Regards, Jan-- 10:32, 14 January 2009 (UTC)Reply[reply]

For me the answer is no longer important. I now use Semantic Mediawiki - takes longer to understand but is the future.
I don't delete the question - maybe someone else is interessted in the answer.
Regards, Jan
Hello Jan, creating a permuted index is a challenge because DPL normally walks sequentially through all articles which match the selection criteria and collects the desired information (in your case template invocations). In your case one would have to store the collected data (using the arrays extension ), re-arrange the order and then produce the output in a final step. With less than 10 lines of code all this is possible:
I know SMW and think it is powerful for expert users. The idea of DPL is to use MW as it is without introducing new syntax for those users who write articles.
Is your book publicly avaialable? If yes, please give a link. Algorithmix 09:32, 21 May 2009 (UTC)Reply[reply]

Problems edit

Hi. I have a problem with labeled section transclusion, the section tags show up along with the transcluded text. This problem only showed up recently; the page was doing fine four months ago when I left it. When I came back a few days ago, no changes have been made to the articles but the DPL pages have broken formatting. It is a Wikia page and I asked the Wikia staff about it too, but they haven't recognized something from their end being the source of the problem either. So here's the problem. Instead of this:


I get this instead:


My wiki can be found here. The formatting error can be seen here.

Please help. Thank you.

-Daarklord 03:50, 16 April 2009 (UTC)Reply[reply]

I installed the extension on a private wiki according to the notes on the page (#include("$IP/extensions/intersection/DynamicPageList.php");), but it doesn't work. When I disable (commtenting out) the extension in the localsettings.php, I can see the page. If I enable the extension I only get a white page displayed on pages with Error: You need to include at least one category, or specify a namespace!, all other pages can be edited and shown. (Setup: Mediawiki 1.13.2, Php 5.1.2 (apache2handler), MySql 5.0.26 und folgende Extensions ExpandTemplates (Version 2008-01-09) BugzillaReports (Version 0.9.8) Cite DynamicPageList Inputbox LabeledSectionTransclusion ParserFunctions (Version 1.1.1) SimpleSecurity (Version 4.2.14, 2008-09-12) SyntaxHighlight (Version r37495) AWC`s MediaWiki Forum )

Thanks for helping -- Joergens.mi 07:33, 2 February 2009 (UTC)Reply[reply]

Can you please download the latest version and test again? There was a major problem in the logic of DPL which dealt with the inclusion of "labelled sections" ... Algorithmix 09:34, 21 May 2009 (UTC)Reply[reply]

Documentation? edit

This article would be more helpful if it actually explained how to use this extension, rather than simply listing what it's capable of.

The article gives a link to the manual. I bet that the manual contains more information than you ever will want to read about DPL ;-)
Algorithmix 09:37, 21 May 2009 (UTC)Reply[reply]

License for DPL edit

The wiki page for DPL says 'no license specified' the source code of the program has one file without any license, another with GPLv2+ and another that just says GPL. Could this please be made consistent? I would like to package DPL for Fedora.

--stahnma at fedoraproject dot org
It has always been GPL. Now it is mentioned in the info box. Algorithmix 09:16, 21 May 2009 (UTC)Reply[reply]

Undefinde Variable edit

Wiki: 1.13.5

PHP: 5.0.5

Apache: 2.0.54

I have installed MediaWiki version 1.13.5 and included the extension dpl. Now I got on my main page this notice notes:

Notice: Undefined variable: result in D:\xampp\htdocs\Lukas\wiki113\includes\Title.php on line 1161

It's a liitle bit strange, because the extension works, but the notes are little bit annoying. What can I do now, has got someone an idea?

Greatz Lukas 08:42, 2 April 2009 (UTC):--Reply[reply]

This should not happen! Are you sure that the error comes from DPL? I have never heard anyone reporting something like that. I suggest the following: Make a clean new test installation of Mediawiki, use DPL as the ONLY extension and then try to reproduce the error. If it still shows up, write a bug report and I will look after it.
BTW: Sometimes new MW versions introduce new errors. The dpldemo wiki runs on 1.13.0 Algorithmix 09:44, 21 May 2009 (UTC)Reply[reply]

Section inclusion does not work edit

I noticed that section inclusion does nothing. In my wiki, as well as on the DPL demo wiki. See the section inclusion test page: it does not output the contents of the sections. It this broken? Using latest MediaWiki and latest DPL. My test page: http://www.jacmoe.dk/wiki/index.php?title=Conditional

Stavrosdr 23:05, 24 April 2009 (UTC) I have exact same problem MediaWiki (Version1.12.0) DynamicPageList2 (Version 1.7.4) ParserFunctions (Version 1.1.1) LabeledSectionTransclusion (Version ?)Reply[reply]

I also have this problem with LabeledSectionTransclusion Stavrosdr 00:19, 25 April 2009 (UTC) I am using PHP 5.2.6-2ubuntu4.2 (apache2Handler) MySQL 5.0.67-0ubuntu6Reply[reply]

Sorry, yes, there was a major bug in DPL which concerned the inclusion of labeled sections. It should be resolved with the latest version now. Please download and test. Algorithmix 09:46, 21 May 2009 (UTC)Reply[reply]

Warning message edit

How can I remove the %DPL-1.7.6- in front of a warning message? The problem is this added in front of the MediaWiki message and I can't find it in the core code. When there are no results I want it to display nothing. --Subfader 12:02, 28 April 2009 (UTC)Reply[reply]

Found it: return '%DPL-' . ExtDynamicPageList2::VERSION . '-' . --Subfader 12:49, 28 April 2009 (UTC)Reply[reply]
Yes, you can remove the prefix in the php source code. It is hard-coded there.
You could use suppresserrors=true to suppress the error message complaininig about an empty result set. Algorithmix 09:48, 21 May 2009 (UTC)Reply[reply]
Yep, I found out about suppresserrors=true later which is the better solution, nontheless I think the %DPL- in fron of the messages are useless. Maybe remind the user that a DPL code is there. --Subfader 11:08, 21 May 2009 (UTC)Reply[reply]

A Bug? edit

I use DPL together with MediaWiki 1.14.0, SMW 1.4.2, DPL 1.7.9 If I follow a link, that is done by the Call-Extension, the CSS-File of SMW is not included. What can I do? The main problem: The field “smwsortkey” is not more hidden, because the style for it is not included. Christian Weiss 14:44, 27 May 2009 (GMT+2)

Please give more details. I assume that the problem has nothing to do with DPL; this means that it also occurs if you use the Extension:Call from the browser's URL-line or within a normal document like this [[Special:Call/:Mypage,a=b]]. I don´t understand your remark about a "style". Are you talking about css? Can you reproduce the error on the dpldemo website? It has DPL 1.7.9 and SMW 1.0 installed. Algorithmix 16:11, 27 May 2009 (UTC)Reply[reply]
The name of the extension is changed and this will create a lot of confusion about which extension infact has the bug. Jeblad 04:03, 31 May 2009 (UTC)Reply[reply]
It's like you said: I call a Template by the Call-Extension, the DPL-Calendar ":Current events" for example. If it's included the normal Way in a Page, in the HTML-Source the "SMW_custom.css" and the "SMW_sorttable.js" are included. If the Template ist called by the "Call"-Extension those files are not included in the HTML-Source. A workaround ist to include those files in the Common.css and Common.js for Skins, so it is included everytime. For the SMW_sortable.js I get then 2x sortbuttons :-) I think, the Call-Extension ist part of your Pakage, so I write my Problem to you. Christian Weiss 10:06, 06 Jun 2009 (GMT+2)

LoF edit

I sthe LoF ment to be set as global in LocalSettings? I'd prefer it as option per DPL call. So I want to use a complex DPL call I would set LoF = 3 or sth inside the call. But if I want to run a very simple call I would set LoF = 0 to save some ressources. --Subfader 15:15, 17 June 2009 (UTC)Reply[reply]

Currently the Level of Functionality is a configurable option which is global for the whole use of DPL in a wiki. It is meant to be a "protection belt" against abuse. I try to anticipate the aguments of those people who must be convinced to run DPL on a website lime WIKIPEDIA. Any suggestion which opens this path is welcome. I guess there will be some user rights administration component in the end - although I do not like this idea very much. -- 21:43, 1 July 2009 (UTC) (Algorithmix)Reply[reply]
kk, thanks for the explaination. I thought it's mainly to make it faster. --Subfader 05:52, 2 July 2009 (UTC)Reply[reply]

DPL Doesn't Work after MW Upgrade from 1.13 to 1.15.1 edit

Hi, I have a private wiki we use as a content Management system at work. I updated the wiki from MW.1.13 to MW.1.15.1, and suddenly DPL doesn't work. For example, I have a page for each of our main applications, with a supbage called 'Troubleshooting'. Below that are more subpages, one for each troubleshooting document. The '/Troubleshooting' subpage consists entirely of DPL to list the child subpages for a user to browse and jump to.

For example (changing the page names to protect proprietary information):

We have a set of pages like so:

* Main:Zazaza 
* Main:Zazaza/Troubleshooting 
* Main:Zazaza/Troubleshooting/Error 51 - File not Found 
* Main:Zazaza/Troubleshooting/Can't Save Configurations 
* Main:Zazaza/Troubleshooting/App Crashes if User Chews Bubble Gum

The top page, Main:Zazaza, describes the application and has a link to Main:Zazaza/Troubleshooting.

Main:Zazaza/Troubleshooting consists entirely of DPL code that will list the three 'troubleshooting' child subpages with links. This page's DPL Code is as follows:

<DPL> <br />

Previously, the DPL worked, and a user browsing to the Zazaza/Troubleshooting page would see a list of clickable links:

 Error 51 - File not Found
 Can't Save Configurations
 App Crashes if User Chews Bubble Gum

Now, since the 1.15.1 upgrade, all that shows up is the following:

 Extension:DynamicPageList (DPL), version 1.8.6 : <dpl_log_1>

Before you ask, no, there is no log being generated or updated anywhere within my wiki home that provides me with a clue as to why DPL isn't working.

I confess to being confused because when I originally downloaded DPL in May or June 2008, this was during the time frame that "old DPL" was known as "Intersection" and 'this' DPL was just known as "DPL", and at the time there wasn't even a reference to the forked versions on the extension page. (I only came to learn all of this with my research this past week.) However, I have verified that I am using semeb.com's Dynamic Page List (was using v.1.6.9, now using v.1.8.6.) I downloaded v.1.8.6 earlier in the week from http://svn.wikimedia.org/svnroot/mediawiki/trunk/extensions/DynamicPageList/, and I just re-obtained the files from the ZIP archive available at http://semeb.com/dpldemo/images/f/fe/Semeb_extensions.zip and redeployed them to be certain. The behavior is still the same as above.

Any help would be appreciated. --ApostleGreen 23:12, 16 July 2009 (UTC)Reply[reply]

DPL doesnt' work with MW 1.15.0 or MW 1.15.1 and DPL 1.8.6
DPL doesn't display anything, but I've to follow up the last Message from ApostleGreen.
The only output is:
Extension:DynamicPageList (DPL), version 1.8.6 : <dpl_log_16>
Please, this is a great extension, could anyone help us?!
Many thanks in advance!!! Timotheus.elias 07:43, 17 July 2009 (UTC)Reply[reply]
Are you sure about all this? It worked fine for me in MW 1.14 and now in 1.16 alpha (I skipped 1.15). So you could still upgrdae to 1.16 alpha but actually I think something else is wrong on your wiki. --Subfader 10:57, 17 July 2009 (UTC)Reply[reply]
Hi Subfader, I tried 1.16 alpha, but it has a conflict with an other extension, so I must use 1.15.1 for now.
The example DPL Code I used in my page:
   |include    = *
This are my used extensions:
  • GroupPermissions Manager
  • PdfExport
  • PdfBook
  • SimpleSecurity
  • wiki2xml extension
  • FCKeditor
  • Lockdown
Thank you!!!
Timotheus.elias 12:49, 17 July 2009 (UTC)Reply[reply]

Well, your example code is wrong. It's either

   include    = *


   |include    = *

Which is the other conflicted extension? --Subfader 13:28, 17 July 2009 (UTC)Reply[reply]

I have the same problem. After upgrade from 1.13.3 to 1.15.1 the extension stop working. I've update extension to 1.8.6, but it doesn't help. --Dnikitin 19:11, 17 July 2009 (UTC)Reply[reply]
It seems I fix my problem. Originally my code was
After I replace Image with File the extension starts working again. --Dnikitin 22:22, 17 July 2009 (UTC)Reply[reply]
Yep the Image namespace was renamed to File in MW 1.14. It needs to be replaced in all DPL calls. Still it works with old [[Image:...]] tags. --Subfader 23:11, 17 July 2009 (UTC)Reply[reply]
Thank you very much vor your quick answer. Now, after I installed your extension correctly :), I'm able to include other pages that are not protected
by the extension Lockdown. Pages in the namespace I've locked with Lockdown extension are not includeable and there will be come following message:
Extension:DynamicPageList (DPL), version 1.8.6 : WARNING: No results.
When I call the following
I'll get all Article's there are not in the extra namespace "basis" and "public". Why is this so?
Although I don't enable Lockdown extension, there'll be the same result!
Many thanks! Timotheus.elias 13:41, 20 July 2009 (UTC)Reply[reply]
The problem was fixed, the Wiki Parameter $wgNonincludableNamespaces was set and therefore this wasn't included. Thanks a lot for your great extension!!! Timotheus.elias 14:06, 20 July 2009 (UTC)Reply[reply]

Parsing Pipes edit

I have run into a little bit of a quandary which I am trying to solve. I am trying to create a template with a set of parameters that are passed from a dynamically created list from DPL. However, when using the pipe character in the formatting for DPL like this:

noresultsheader=Nothing found...</DPL>}}

...the pipe character is not parsed by the templating system, I think because of the order in which things are processed... The result is all the articles listed like this: "|Article1|Article2", and so on, instead of passing each one as a template parameter. I have been trying, but I can't think of a way around this. Does anybody have any thoughts on this? --Bsmithme 21:12, 18 July 2009 (UTC)Reply[reply]

I have tried using subst:Hot_issues but that had no effect. I've also tried creating a template with "|", but that didn't work either. I think I am approaching it wrong...--Bsmithme 21:15, 18 July 2009 (UTC)Reply[reply]
Try ¦ --Subfader 21:16, 18 July 2009 (UTC)Reply[reply]
No luck there. I think ¦ is only used when you are using #dpl and need a pipe in the dpl parameters, but I'm not sure (versus <DPL> where you can use pipes with impunity). --Bsmithme 21:29, 18 July 2009 (UTC)Reply[reply]
Dunno your template but shouldn't it be {{Hot_issues<DPL> without | cos that will be return in front of the first result already. Try
Finds only pages in cats Application AND Hot_issues. Also [[%TITLE%]] doesn't make much sense to me when should find pages from all namespaces except subcats. If it doesn't help post your template here as I can't image what you try to do there by sending an unknown ammount of parameters (each page link) to the template. --Subfader 22:15, 18 July 2009 (UTC)Reply[reply]
Think the best way to illustrate what I'm trying to do is this:
{{Hot issues
| DPL result 1
| DPL result 2
| and so on

So that the page calling the hot issue template is automatically populated based on the results of the DPL query. I'm starting to think it might not be possible to do it this way. --Bsmithme 23:45, 18 July 2009 (UTC)Reply[reply]

Oh, but you are on to something with your suggestion and I think I can get it to work with some more fidgeting. --Bsmithme 23:52, 18 July 2009 (UTC)Reply[reply]
Aha! I got it with this:

Thank you so much for your assistance, Subfader. --Bsmithme 23:56, 18 July 2009 (UTC)Reply[reply]

RESOLVED: Fatal error edit

After upgrading my wiki to MW 1.15 I got the error message:

Fatal error: Unsupported operand types in /home/schlott/public_html/wiki/includes/parser/LinkHolderArray.php on line 33

and the extension stoped working.

The solution was inside the DynamicPageList/DPL.php with the following statement in Line 36:

// cloning the parser in the following statement leads in some cases to a php error in MW 1.15
// You must apply the following patch to avoid this:
// add in LinkHoldersArray.php at the beginning of function 'merge' the following code lines:
//		if (!isset($this->interwikis)) {
//			$this->internals = array();
//			$this->interwikis = array();
//			$this->size = 0;
//			$this->parent  = $other->parent;
//		}

After adding the mentioned code lines to LinkHoldersArray.php the extension works just fine. -- Flaming Moe

Does this still happen in later versions of MediaWiki? I'm experiencing the same issue with version 1.17, should I try this solution? - 18:53, 17 June 2012 (UTC)Reply[reply]

Comment on differing versions by Algorithmix edit

  • Note that the version running on Wikimedia sites was at some point in time renamed to Extension:Intersection to avoid confusion with the extension described here. But the documentation still was talking of "DynamicPageList" and the SVN path was not renamed.
  • Recently 'Intersection' claimed back its ancient name and that is why you now find the documentation of 'Intersection' under 'Extension:DynamicPageList'.
  • On the other hand the DPL extension described here was still named 'DynamicPageList' and new functions were added. At some point in time downward compatibility with the version running on Wikimedia sites was lost. The extension was renamed to 'DynamicPageList2' but the documentation was still talking of "DynamicPageList".
  • Then another bunch of functionality was added and downward compatibility (with DPL2) was lost. The name of this version was changed back to DPL (which was thought to be 'free').
All this has created much confusion. Read below for a suggestion on how to re-unite the different variants.

This extension Dynamic Page List (DPL) has the same roots as Extension:Intersection. Until recently DPL was almost - but not exactly - downwards compatible with Intersection. A lot of confusion comes from the fact that Intersection uses the tag <DynamicPageList> whereas Dynamic Page List (DPL) uses the tag <DPL>.

DPL offers functionality that goes far beyond Intersection. Some of this functionality might be useful also on Wikimedia sites. But the problem is that inexperienced users or people with 'not-so-good-intentions' might write DPL statements which create significant database load.

A good solution - which also puts an end to all naming ambiguities of DynamicPageList, DPL, DPL2 and Intersection looks like this:

  1. There should be only ONE extension.
  2. It should be called DynamicPageList (short name DPL).
  3. It should listen to the tags DynamicPageList and DPL for compatibility reasons.
  4. Its sources should be in the mediawiki SVN
  5. It should be strictly downward compatible with Intersection.
  6. It should offer a configuration switch (let us call it LevelOfFunctionality = LoF) which lets the administrator of a wiki decide, how much functionality will be offered to the users:
    • LoF = 0 is exactly identical with Intersection as of today.
    • LoF = 1 offers additional features which do not affect performance (mainly related to output formatting)
    • LoF = 2 offers additional features which are on the same conceptual level as Intersection like selection of pages by use of templates or by pagelinks. As the underlying table structures in the mediawiki database design are very similar to categories the performance cost of theses features are comparable in magnitude with Intersection's current features
    • LoF = 3 offers additional features which are more cost-intensive, like e.g. content transclusion from pages that occur in the DPL result; we think that a dedicated DPL cache could allow to offer these features also on high traffic sites - but this still has to be proved
    • LoF = 4 offers a last group of features which are a somewhat exotic and could create trouble if used by ignorant people (batch updates and batch deletions based on DPL query results)

--Algorithmix 17:18, 1 June 2009 (UTC)Reply[reply]

DPL 1.8.0 made a huge step into that direction.

After some bugfixes we now have DPL 1.8.4 as a stable release which can serve as a base for re-unification of all DPL variants..

Please help testing! --Algorithmix 21:10, 15 June 2009 (UTC)Reply[reply]

Moved from the main page. GreenReaper 20:02, 22 August 2009 (UTC)Reply[reply]
My own thoughts on this: it's a good idea, but performance is a huge consideration. I suggest investigating ways to avoid loading DPL code unless it is required, particularly $wgAutoloadClasses. Right now APC shows that it is touching all the code on every page access, and that's a significant cost when you have a large number of pages being accessed. GreenReaper 21:51, 22 August 2009 (UTC)Reply[reply]
The latest version of DPL only loads a small portion of its php code on the initial require_once(). ONLY if there is a DPL call within a page the rest of the php code will be loaded. Which version did you test? Algorithmix 05:53, 23 August 2009 (UTC)Reply[reply]
Ah, indeed it does - thank you! I was using 1.8.6 and it seems you made that change in 1.8.7 - I updated to 1.8.8 and now only DPLSetup.php is showing up on each load. That is a big improvement in code loaded - from 1.1Mb to 150kb. :-) GreenReaper 19:55, 23 August 2009 (UTC)Reply[reply]

Trying to List Pages... edit

Trying to List Pages within a Namespace in Category Mode, Alphabatized on a non category page. Sounds ridiculous however this is the syntax that i am using:


What i am trying to do is show all pages in the article namespace on a page in category mode alphabetized by the page title rather then the namespace. Currently all pages are organized under "A" because the pages are named Article:Page Name. I want to eliminate or mask the Article so that they are organized by Page Name.

Kevindank AT Gmail.com

Hmh, you aren't very clear.
1) is there really a custom namespace called "Article"? Cos otherwise you mean Main: "namespace="
But I guess I know what you mean. Like in this example you don't want U headings but 0-Z... I dunno a solution :/ --Subfader 21:17, 21 October 2009 (UTC)Reply[reply]

Workaround edit

If you apply a very small patch you can use


to get the desired result:

find (near line 1860 in DPLMain.php in the latest version)

               case 'titlewithoutnamespace':

and add the following line immediately after that line:

                   $sSqlSortkey = ", $sPageTable.page_title ".$sOrderCollation." as sortkey";

I will add this code line to the next release. In fact, the patch will make the new behaviour the default (which is o.k., I think). Use ordermethod=title to switch to the old behaviour. 07:01, 22 October 2009 (UTC)Reply[reply]

This worked perfectly Thank You.


is it possible to tie this to DISPLAYTITLE to sort pages by their DisplayTitle?

installation instruction problems edit

Thanks for this powerful extension. In order to help others to use it, I want to report two problems I just had in following the installation instructions in the article.

The instructions say:

add include("$IP/extensions/DynamicPageList/DynamicPageList.php"); to LocalSettings.php

However, the actual file downloaded for v1.14 was named DynamicPageList2.php. This modification worked:


The second problem is probably due to my lack of familiarity with PHP. The instructions appear to say to add a function call in LocalSettings after the include() statement above to control the richness level, like this:


However, this caused a fatal error, so I commented it out. Should the call be like this?


--AJim 21:20, 30 October 2009 (UTC)Reply[reply]

DPL extension inserts a blank line headline edit

Blank line in headline

Problem: DPL extension inserts a blank line in the article title (see picture). Other articles that do not use DPL, displayed without distortion.

I use the original Monobook skin and the following versions of components:

  • MediaWiki - 1.15.0
  • PHP - 5.2.8 (appache)
  • MySQL - 5.1.30-community-log

Can you tell me how to solve the problem, please. Thanks!

Kabanoff 13:57, 5 November 2009 (UTC)Reply[reply]

Never had this problem. But since it's also on the DPL website I guess it's not so easy to fix? --Subfader 14:35, 5 November 2009 (UTC)Reply[reply]
Perhaps. The problem on this wiki appears when the user is not logged in the system. In my wiki blank line appears wherever there is DPL. Discussion of this issue is on DPL issue page --Kabanoff 08:53, 6 November 2009 (UTC)Reply[reply]
The simplest way to go is to edit the main.css of your own skin. In Monobook, search p-cactions, you will see "top: 1.3em;" (or similar). Change it to "top: 2.3em". It may work. --Dullmau 20:26, 10 June 2010 (UTC)bReply[reply]

Having DPL Maintain #section Links edit

If the pages I'm building my DPL from have links like [[#section|A Section]], is it possible to to have DPL maintain the url of the page with that specific section, rather than have it change it to the page that has the DPL on it? — Cosmotron 18:56, 8 November 2009 (UTC)Reply[reply]

Template:DPL_Extension creation as potential redirect loop edit

There is a DPLSetup.php routine, commonSetup(), which attempts to create an {{Extension DPL}} template using the userid of the first user to visit the wiki after the extension is installed:

private static function commonSetup() {
        if (!isset(self::$createdLinks)) {
                'resetLinks'=> false, 'resetTemplates' => false, 
                'resetCategories' => false, 'resetImages' => false, 'resetdone' => false , 'elimdone' => false );

        // make sure page "Template:Extension DPL" exists
        $title = Title::newFromText('Template:Extension DPL');
        global $wgUser;
        if (!$title->exists() && $wgUser->isAllowed('edit')) {
            $article = new Article($title);
            $article->doEdit( "<noinclude>This page was automatically created. It serves as an anchor page for ".
                              "all '''[[Special:WhatLinksHere/Template:Extension_DPL|invocations]]''' ".
                              "of [http://mediawiki.org/wiki/Extension:DynamicPageList Extension:DynamicPageList (DPL)].</noinclude>",
                              $title, EDIT_NEW | EDIT_FORCE_BOT );
            die(header('Location: '.Title::newFromText('Template:Extension DPL')->getFullURL()));


Two issues with this:

  • (minor) The external link Extension:DynamicPageList (DPL) points to a disambiguation page here instead of to the actual extension info.
  • (not so minor) If creation of the template fails, the user is redirected to Template:Extension DPL regardless, and the failed attempt to create the template is repeated until the browser detects this as a redirect loop and shuts down.

I've noticed that new installs, if started with just a blank set of database tables and a LocalSettings file (without running the MediaWiki installer again for the new wiki), are prone to go into an endless HTML redirect loop because of this code. Attempts to run maintenance/update.php from the command line may also abruptly end with errors if the extension is trying to create this page during the "update.php" run and the database is not yet updated to the latest MW format (and therefore not ready for the template creation attempt).

There needs to be some error handling; if the creation of the placeholder template fails, don't just keep trying forever - at least not if this is going to return errors or redirect loops. --Carlb 14:12, 9 November 2009 (UTC)Reply[reply]

Dynamic Pagelist vs. Semantic Mediawiki edit

I have started a Comparison of Dynamic Pagelist x Semantic Mediawiki. Please help to give valuable information for a good choice. --Jannis 19:19, 22 December 2009 (UTC)Reply[reply]

2010 edit

[SOLVED] White page after including Semantic Media Wiki Extension in LocalSettings.php edit

Hello, I installed the Semantic Media Wiki extension on a Media Wiki 1.16.0 According to the install notes on the page I appended the following two lines to the LocalSettings.php:


After that I get a blank page on every URL of the Wiki. Set error_reporting to E_ALL (in LocalSettings.php, SMW-Config-Files) but also got a blank page.

Also tried the hint from the Semantic Wiki Site with no success:

ini_set( 'memory_limit', '100M' );

When I comment the both lines out everything works again.

(Setup: Mediawiki 1.16.0, PHP Version 5.2.6, MySql 5.0.45, Semantic Media Wiki Extension 1.5.3 stable)

Would apreciate any hint.

This page is only for support for the DynamicPageList extension. You're more likely to get a response if you ask the SMW people. With that said, Did you add the:
ini_set("display_errors", 1);

as the very first lines of LocalSettings.php (directly below the opening <?php )? If that still doesn't work, try setting error reporting to E_ALL directly in your php.ini file. You can also try checking your webserver's error log as well (doesn't usually have php errors in it, but if its some sort of config problem with your webserver it might have relevant information). Bawolff 22:31, 26 November 2010 (UTC)Reply[reply]

Thanks for the reply...think ini_set got the errorReporting working. Now there is some output I can work with: http://www.mediawiki.org/w/index.php?title=Extension_talk:DynamicPageList_(third-party)&action=edit&section=38 Call to undefined function enableSemantics() in /srv/www/vhosts/filerepos.de/httpdocs/websites/semwiki/LocalSettings.php on line 138

[SOLVED] I accidently downloaded the wiki and the extension with different user...so the wiki wasnt allowed to access the extension. Changed extension files owner to the same owner as the wiki and so everything works now. Thanks for the error reporting hint which allowed me to find my mistake

Undefined index and .default edit

I try to make the DPL-Extension read out a category and get the parameters of a template in the articles of this category. They are meant to be used in another template. I saw another wiki which did it the same way as I did, but I get a strange Error while using the preview on this:

  category = Some Category
  mode = userformat
  includepage = {Template in articles} Kr
  allowcachedresults = true

"Notice: Undefined index: tip ... EditPage.php". The line is this: "$tip = $tool['tip'],". This is strange but probably not that important. The real problem I got ist, that the extension always adds an ".default" at the end of the template. So I get a long list which just says "Template:Template in articles Kr.defaultTemplate:Template in articles Kr.default...".I don't really get the origin of the problem and couldn't find an answer anywhere. I didn't change anything in the basic code of mediawiki, except for some extra buttons i added in EditPage.php. There are also no extensions, that could affect the DPL extension.--Eski123 12:14, 2 January 2010 (UTC)Reply[reply]

My five cents on this: according to doc, the DPL engine calls a template with the additional sufix ".default" when a page listed in the result does not use the specified template. Pierrem100 14:49, 26 October 2010 (UTC)Reply[reply]

Problems with missing subheads edit

DPL is apparently crashing when used with a subhead that doesn't exist on one of the pages included by Category.

I have the following DPL code on a page called "Current projects":

=Projects in process=
 |include = #Project steward, #Need
 |table=class="sortable", Project, Steward, Need

=Completed projects=
 |category=Projects, completed
 |include = #Project steward, #Final accounting
 |table=class="sortable", Project, Steward, Final Accounting

The first DPL call works if I temporarily clip out the second DPL cal, but including the second DPL call displays:

Fatal error: Call to a member function getPrefixedDBkey() on a non-object in /Library/WebServer/EcoReality/wiki/includes/parser/Preprocessor_DOM.php on line 994

I then looked over the pages in the Category "Projects, completed" and discovered several of them did not have a subhead called "Final accounting." These are old pages, and this worked once upon a time!

For now, I've removed "Final accounting" from the second DPL call, but it seems it should behave better than this in such a case, no? Have I messed up something to cause it to misbehave this way?

See it fixed at: http://www.ecoreality.org/wiki/Current_projects .

If you haven't found it, this appears to be a problem with the DOM parser that has a patch on bugzilla. (I forgot to sign AND log in, awesome) --WeaverThree 20:03, 23 March 2010 (UTC)Reply[reply]

Spaces and underscores edit

It seems that the "titleregexp" parameter doesn't interpret spaces and underscores the same way. In fact, since page names can't have spaces in them, any time there is a space it just flat out fails. This would ordinarily not be such a big deal, so, okay, you learn not to use spaces, however i have a template for detecting direct subpages of a page (but not sub-subpages). the regexp is DynamicPageList (third-party)/[^/]*$ however, if used on a page with a space in the name, DynamicPageList (third-party) returns a space there where dpl requires an underscore. It seems to me that spaces and underscores should be totally interchangable in dpl, as they are in the rest of MW. DeFender1031 11:22, 29 January 2010 (UTC)Reply[reply]

MediaWiki SVN code incompatible? edit

The code in the mediawiki SVN does not work as per the instructions on the page. I wonder if we should remove this code to avoid confusion? JonathanWilliford 20:44, 6 February 2010 (UTC)Reply[reply]

I found out that some MediaWiki users are trying to copy some of the functionality available from the zip file into the MediaWiki repository, while making sure that the code meets MediaWiki's coding standards. I created a section on the main page to comment on some of the differences in the code that is pertinent to users of the extension. --JonathanWilliford 22:24, 6 February 2010 (UTC)Reply[reply]

DPL breaks references in Cite? edit

I'm having a weird problem with DPL and the Cite extension (Extension:Cite). A <ref>asdf</ref> reference won't show up in the <references/> section if any DPL query is run in between. Dug into the code a bit and it seems like DPL clones the parser and does a clearState(), maybe that clears the active cite object as well for some reason? Anyone else have this problem? Is there a workaround? I'm running MediaWiki 1.15.1, DPL 1.8.9 with PHP 5.2.6. --Shadowie 15:02, 27 February 2010 (UTC)Reply[reply]

Found an active bug about this now as well. --Shadowie 15:07, 27 February 2010 (UTC)Reply[reply]
This is still a problem. 23:03, 15 November 2012 (UTC)Reply[reply]
This is happened to me on a wiki running 1.19 a few months ago, but I bookmarked it for later and ended up abandoning the DPL scheme for unrelated reasons before looking for a resolution. Now I'm using DPL heavily on a corporate wiki and I need both of these functionalities intact.
It doesn't matter where the DPL function comes from, even transcluded from a subpage, it clears the {{reflist}}. References that appear after (or inside of) the DPL function are loaded normally, but the only way to make the references from before the first DPL function appear seems to be to place a {{reflist}} above the DPL function on the page, which is a problem for so many reasons. Does anyone know of a workaround?
I'm running Mediawiki 1.20, DPL 2.01, PHP 5.3.19, and MySQL 5.1.30. Cheers. Michael Chidester (talk) 16:38, 30 January 2013 (UTC)Reply[reply]

Great and easy: Searchable Tables edit

I use the TableTools (Firefox-Extension) to search the tables generated with DynamicPageList (Mediawiki-Extension); see here [1]

With the Firefox-Extension installed you can right-click into a table and choose

  1. show Filter (german: Filter anzeigen)
  2. show Searchfilter (german: Suchfilter anzeigen)

With the first you get lists where you can choose an item in the table-heading and get all the rows matching this item.

With the second you get searchfields in the heading to use for a wildcard-search.

Both functions are very (!) usefull for the DynamicPageList-tables. But it is not userfriendly for less sophisticated users to right-click to get the function. I would like to put such functionality with an easy dpl-command into the heading, similar to the magicword "wikitable" or "sortable": "searchable". Now I wonder if it would be possible to integrate such a great feature directly into DynamicPageList??

I hope that others are also interested in such a feature.

Jan, -- 20:58, 1 March 2010 (UTC)Reply[reply]

Bug found in Mix/Max revisions edit

Lines 2376 - 2381 of DPLMain.php should be modified as follows to use the abstract table names:

if ($iMinRevisions != NULL) {
 $sSqlWhere .= " and ((select count(rev_aux2.rev_page) from $sRevisionTable as rev_aux2 where rev_aux2.rev_page=$sPageTable.page_id) >= $iMinRevisions)";
if ($iMaxRevisions != NULL) {
$sSqlWhere .= " and ((select count(rev_aux3.rev_page) from $sRevisionTable  as rev_aux3 where rev_aux3.rev_page=$sPageTable.page_id) <= $iMaxRevisions)";
} 15:17, 19 March 2010 (UTC)Reply[reply]

Setting parameter without using template? edit

Hi, it seems that all parameters are set in a template. In my wiki, there is a pretty standardized section and i would like to implement DPL on it. It's not a template but just a list of 1....2....3...list. Is there any markup tag that i can tell DPL that item01 = 1..  ; item02 = 2... ; item03 = 3.... ?

The current method is like this. It's actually good but in a FCKeditor-based Wiki, it may be too difficult to ask laymen to learn it.

{{ Country
|name=Republic of Nigunda


--Dullmau 12:57, 19 June 2010 (UTC)Reply[reply]

MediaWiki 1.17alpha and bug 22675 edit

I downloaded the daily build of MW 1.17 alpha (12:13, 20 June 2010 - revision: r68310) core code and extensions and this seems to be broken. Symptoms are the same as reported in bug 22675 four months ago, the output appears on-screen as an HTML source code dump (<a href="...) instead of as hyperlinks in their clickable form. The Wikimedia (intersection) version of the extension still works normally with no other change to configuration. --Carlb 23:03, 20 June 2010 (UTC)Reply[reply]

This applies to MW 1.16 beta3 as well. Thorncrag 02:47, 29 June 2010 (UTC)Reply[reply]
The same problem with MW 1.16 beta1 EduRam 09:41, 1 July 2010 (UTC)Reply[reply]
Oops. I just downloaded r68608 and it works with 1.16 beta3. I imagine it will with 1.17 as well. Should have done that before. :) Thorncrag 01:36, 30 June 2010 (UTC)Reply[reply]
Er, now it appears I was somewhat incorrect. It appears as though some DPL statements are functioning and some are not, in r68608. Continuing to investigate. Thorncrag 22:31, 30 June 2010 (UTC)Reply[reply]
Actually,this issue fixed in r68812 completely.You can download the new DPLMain.php to solve this problem.--Xlsoul 07:43, 21 July 2010 (UTC)Reply[reply]

imagecontainer edit

Hi, I'm using DPL and imagecontainer, but I'm not sure what the problem is.

imagecontainer=Constructed items (1-24)

Shouldn't this give a list of all of the images used on the page? It's blank. 21:37, 1 July 2010 (UTC)Reply[reply]

imagecontainer might be disabled - it needs the functionalrichness parameter to be at least 2. (if that is the case, I have no idea if there would be an error of some sort. this is just a guess, I don't know much about DPL2). Also check your version. imagecontainer was added in 1.7.4, some sites use older versions (wikia for example uses 1.6.4) Bawolff 23:06, 1 July 2010 (UTC)Reply[reply]
Well, that would probably be the problem (the version; I'm using wikia). Is there any other way to make a list of all the images on the page? 00:51, 2 July 2010 (UTC)Reply[reply]
You can use the api - http://runescape.wikia.com/api.php?titles=Constructed_items_(1-24)&action=query&prop=images&imlimit=max (if you need pretty output you can use either javascript or xslt) Bawolff 07:44, 2 July 2010 (UTC)Reply[reply]
Thank you very much. I ended up using a mix of DPL and AWB to figure it out :). 06:16, 9 July 2010 (UTC)Reply[reply]

PHP error since moving host edit


Anyone got an answer for this PHP error, which has been appearing ever since I switched to a new web host? DPLs have stopped appearing on the pages, seems this error is to blame.

Parameter 3 to ExtDynamicPageList::dplTag() expected to be a reference, value given in /[snip]/includes/parser/Parser.php on line 3243

I've tried upgrading DPL, no luck. Is it a permissions problem perhaps? 17:14, 6 July 2010 (UTC)Reply[reply]

You have to change the signature of the method dplTag() in line 865
public static function dplTag( $input, $params, $parser ) 15:30, 30 July 2010 (UTC)Reply[reply]
Thank you, it works (I've had this problem since I'd upgraded to PHP 5.3.x. ;)

I've noticed some weird issues with PHP 5.3. The above patch resolves some but not all. The <DPL> tag is now working but {{#dpl}} is still broken, at least on my Ubuntu localhost with PHP 5.3. On the server, with RHEL and PHP 5.3 (same minor version) neither dpl thing is working. I've looked a bit into the differences between PHP 5.2 and 5.3, mostly the by-reference parameter stuff but so far I haven't fixed this yet. Guaka (talk) 14:12, 21 February 2012 (UTC)Reply[reply]

I did some Automated PHP 5.3 compatibility testing (based on PHP_CodeSniffer) and (unfortunately) only got some warnings about split() (which should become preg_split()). Guaka (talk) 15:12, 21 February 2012 (UTC)Reply[reply]

Image inside a template edit

Is there by chance a way to make a list of all of the images that are used in a template? For instance, on this page, I'd like to have it add File:New Rune Scimitar.png . It's a parameter on the template, not part of the template itself. Is there a way to do so? 06:19, 9 July 2010 (UTC)Reply[reply]

Anyone? 22:10, 10 July 2010 (UTC)Reply[reply]

Parser function after a backup edit

I seem to have a strange issue after restoring a backup of my wiki on another computer. Both computers are using DPL version 1.8.9. I have a bunch of pages that use the parser function variant ({{#dpl: ...}} through some templates. For some reason, they display incorrectly on the new computer. Basically they just show the function then all of the parameters in what looks like a PRE tag.

The parser tag works fine. I can take the same queries and change them to the tag variant on a test page and they work great. The trouble is I need these to work in templates, so the function is needed. Anybody have any ideas what would cause this? - Glycerine102 14:50, 19 July 2010 (UTC)Reply[reply]

No idea whats causing your original issue, but you can also try {{#tag:DPL - see Help:Magic_words#Miscellaneous. Bawolff 01:42, 20 July 2010 (UTC)Reply[reply]
I highly suspect this to be an issue with PHP 5.2 vs 5.3... Guaka (talk) 15:37, 21 February 2012 (UTC)Reply[reply]

Parser versus Hook change? edit

Does anyone know what might have changed in the code to cause the following statement to no longer include the category here, as seen below:

{{#dpl:category={{PAGENAME}}|category=Application Error|notcategory=Subtopic-topic|replaceintitle=/{{BASEPAGENAME}}\//,|format=,\n*,[[{{BASEPAGENAME}}/%TITLE%{{pipe}}%TITLE%]],|notnamespace=Category|noresultsheader=There are no symptom entries for this application.[[Category:Articles with no symptom entries]]}}

The odd thing is that it is actually working for one of my templates. I resolved the issue by converting to the <DPL> hook instead. Still, it seems strange that this suddenly stopped working. Thorncrag 20:31, 18 August 2010 (UTC)Reply[reply]

And I have just discovered that my workaround will not suffice because using the hook causes replaceintitle to not function the same as when using the parser call instead. Thorncrag 21:18, 18 August 2010 (UTC)Reply[reply]
Note, as said in the thread above this one, you can also use {{#tag:DPL to access the <DPL> tag as a parser function which should have the exact same behaviour as <DPL> (compared to {{#dpl: which has slightly different behaviour compared to <DPL>). Bawolff 17:41, 19 August 2010 (UTC)Reply[reply]
Even with this tag format, the noresultsheader is not honored, for some unknown reason. Thorncrag 19:45, 19 August 2010 (UTC) Due to being dyslexic I misread the suggestion... This actually might work, I shall troubleshoot further.    Thorncrag   23:31, 7 October 2010 (UTC)Reply[reply]
This might also be a PHP 5.2 vs 5.3 problem... Guaka (talk) 15:45, 21 February 2012 (UTC)Reply[reply]

Is this extension provoking an early call to ParserClearState? edit

On Extension talk:VariablesExtension#Big Job Queue/Import bug solved in 1.3 a bug in combination with Extension:VariablesExtension was reported. It seems like DynamicPageList triggers an early call of the hook ParserClearState which could cause trouble with several extension. Do you have any idea how this happens and what would be the best solution to solve this problem between the extensions? --Danwe 04:35, 31 August 2010 (UTC)Reply[reply]

70760 and mw 1.16+ edit

i know it's not the most secure thing in the world, but do they still play nice together? redekopmark 18:38, 13 September 2010 (UTC)Reply[reply]

I'm not sure what the number of 70760 is, however as far as i know they still play nicely together as long as the version of DPL is post rev:68812. However with that said, the categorylinks table changed quite a bit in 1.17 (aka current svn head). Some features might break in subtle (or perhaps not so subtle ways) because of that. It will certainly be less efficient for plain ole' category listings (but then again this is a very inefficient extension, so if you care about efficiently, I doubt you'd use it). Short answer: In my testing it still works, but no guarantees (+ the XSS issue). Bawolff 22:10, 13 September 2010 (UTC)Reply[reply]
okay, thanks, the 70760 is the revision that i got when i downloaded the trunk version earlier today and i'm only planning on using it with 1.16 until 1.17 hits stable, again, thanks redekopmark 04:29, 14 September 2010 (UTC)Reply[reply]

DPL & Nested Templates? edit

I may be missing something so I am posting the question here. Can DPL query variables passed to a nested template? Meaning, ...

  • You have a page named Resource1 which uses a template called ResourceType1 which is a member of the Asset Category.
  • Within template ResourceType1 you pass variables to and call the template called AssetInfo.
  • You then construct a DPL query which based on the Asset category queries all pages member of Asset and lists the variables found on the nested AssetInfo template

The rational for such a construct would be to list AsseInfo common to all resources which may use different ResourceType templates (type1, type2, etc) but are all members of Asset. Since the include/includepage line in DPL table output must be consistent, querying the nested common template seems the best approach but does not work. please advise?, thanks ahead of time for replies 23:23, 4 October 2010 (UTC)Reply[reply]

Replace in title breaks with titles that contain parentheses edit

I've just discovered that an article title which contains parentheses causes the replaceintitle statement to break in that it will no longer perform any longer. In context, I have a replaceintitle which is supposed to remove the BASEPAGENAME from the title or an article that is a subpage, so that when I output title I can output only the name of the subpage instead of the entire trail. I still need to do further troubleshooting to see if it is actually BASEPAGENAME or %TITLE% which is breaking. Nevertheless, it's clearly an issue with the extension.    Thorncrag   22:41, 7 October 2010 (UTC)Reply[reply]

Note, per issue I reported above, I changed to #tag:DPL .... which is what bawolff had suggested. Unfortunately I misread it a long time ago... Anyhow that seems to have sufficiently worked around this issue.    Thorncrag   23:30, 7 October 2010 (UTC)Reply[reply]
Well, changing to tag:DPL is till not yielding the results I need. It seems that several of the DPL options are not honored when changing to it. So I'm back to parentheses breaking again.    Thorncrag   01:12, 8 October 2010 (UTC)Reply[reply]
{{#tag:DPL Should take the exact same syntax as <DPL>. If there's something that works for <DPL> but not {{#tag:DPL, that's probably a bug in mediawiki (core) not the extension, since converting {{#tag:DPL to <DPL> is part of the parser. (With that said, I'm not sure how it'd help you with your issue, since the two should be exactly the same with exception of parsing the args before passing to DPL.). Bawolff 22:19, 26 October 2010 (UTC)Reply[reply]

Use with TreeAndMenu Extension ? edit


I only need this:


..To dynamically add all pages to a tree that is created by the Extension TreeAndMenu. I´ve tested it and it works great. Though I´m planning an opened wiki I´m a bit scared about the red box on this extensions main page telling me that it has a major security risk.

Is it possible to enable this extension only for a specific (admin) page or to eliminate the security risk by adding some contraints?

Thanks in advance! 18:47, 4 December 2010 (UTC)Reply[reply]

The security risk will be eliminated in the next version. If you protect the the page with the DPL statement against changes, however, there should be no risk, even with the current version. 17:27, 10 December 2010 (UTC)Reply[reply]
Hmm? Someone could just write a new DPL on an unprotected page. You'd also need to make it so DPL's only ran on protected pages. (I think there might even be an option for that. can't remember). Bawolff 19:09, 10 December 2010 (UTC)Reply[reply]

Hi, thaks Bawolff, I´ll take a look at the settings soon. If you remeber please post it here. 09:33, 11 December 2010 (UTC)Reply[reply]

ExtDynamicPageList::$options['RunFromProtectedPagesOnly'] = "NO DPL FOR YOU!"; See http://semeb.com/dpldemo/index.php?title=DPL:Manual_-_Source_and_Installation#DPL_Security (Note I haven't looked at the code implementing that, so I can't vouch for its security in any way or form, but the manual claims that it will work). Bawolff 17:09, 11 December 2010 (UTC)Reply[reply]

Hi, thanks a lot! Have a nice christmas time!

Hi again. Sadly that was not the solution. If the option to allow DPL only on protected pages is enabled this also affects the NavTree (Extension: TreeANDMenu) that needs DPL to work propperly. What I need is DPL to only work in the sidebar :-). But I don´t know if that is easily possible?

Thanks! 19:30, 19 December 2010 (UTC)Reply[reply]

2011 edit

Tree and Menu and DPL - Advanced use edit

I'm currently using Tree and Menu and DPL to generate lists as shown in the Example. Works fine.

{{#tree:id=ToolsMenuTree|openlevels=0|root=Tools, Tips and best practice|
* Overview (Introduction Page)
{{#dpl:category=Tools and Tricks|format=,**,%PAGE%\n,}}

The problem is that our wiki will have a lot of pages and subpages, making the list expand really fast with similar named entries such as:


With the example structure above, is there a way to automatically create subfolders for all subpages using DPL syntax? Should be looking something like that


Any hints would be greatly appreciated. (Mike) dpl nested

For subcategories you could use nested queries. Not sure how to implent that for subpages. You may need titleparts and titlematch.
I once wrote a subpages script but it had some bug in the order iirc. --Subfader 19:20, 21 January 2011 (UTC)Reply[reply]

Error on line 442 edit

Hello, how can I solve this error?
Deprecated: Function split() is deprecated in /home/tibiawi/public_html/extensions/DynamicPageList/DynamicPageList2Include.php on line 442

Replace the split() call with preg_split(), that should be equivalent. :) Make sure the line is passing the arguments as it should, though, the function headers are subtly different. -pinkgothic 14:36, 28 January 2011 (UTC)Reply[reply]

DPL transclusion and performance tip edit

Better write of the (meanwhile deleted) ramble below is at User:Pinkgothic/DPL, which is very layman oriented, so probably going to bore most people out of their minds, but I like having something I can link anyone to. :) -pinkgothic 15:49, 28 January 2011 (UTC)Reply[reply]

Deleted the ramble, better read the extended version ;-) --Nakohdo 17:56, 8 February 2011 (UTC)Reply[reply]

Semeb.com Troubles? edit

The whole /dpldemo/ folder seems to have disappeared from semeb.com. Is there somewhere else we can go to get to the manual? –DamnedScholar 20:51, 4 February 2011 (UTC)Reply[reply]

Seems to be back: http://semeb.com/dpldemo/ --Nakohdo 17:48, 8 February 2011 (UTC)Reply[reply]
So it is. –DamnedScholar 03:48, 14 February 2011 (UTC)Reply[reply]

Issue with replaceintitle edit

I'm having an issue with replaceintitle when attemtping to do a replacement on a title which includes an apostrophy.

Here is my dpl call:

|format=,\n* [[%PAGE%|%TITLE%]],,

The above works perfectly on, for example, "John Smith", but "John O'Shea" fails to return any results. I've tried a number of ways to escape the apostrophy with no success, so any help would be greatly appreciated.

-AerosAtar 20:04, 19 February 2011 (UTC)

Extension:StringFunctions#.23replace:, Extension:MultiReplace --Subfader 00:29, 20 February 2011 (UTC)Reply[reply]
I've tried using a #replace call from ParserFunctions (running 1.16.2), but it fails under the same circumstances. It is possible I wasn't writing the regexp correctly though. What would you suggest I try within the #replace call?
-AerosAtar 22:37, 21 February 2011 (UTC)
Its because the ' in {{PAGENAME}} is outputted as a &#39; to avoid making italic/bolding. You need to somehow use the replace parser function to replace the &#39; with a ' (And hope replace doesn't similarly replace ' character). Bawolff 03:58, 26 February 2011 (UTC)Reply[reply]
Using {{#replace:{{PAGENAME}}|&#39;|'}} or {{#replace:{{PAGENAME}}|&#39;|%27}} doesn't seem to make any difference. Could there be something else causing this? It does only seem to be the one page with a ' in the title that is having a problem, which is why I have made the assumption that is the problem. -AerosAtar 16:37, 27 February 2011 (UTC)
Probably something to do with at what stage the &#39; is getting converted to a '. Perhaps using the tag version (aka <dpl> instead of {{#dpl:...) might work better since tpyically tag extensions have the content passed unmangled to the extension hook. (thats a bit of a long shot though). Bawolff
On a related note, this issue isn't limited to DPL, see bugzilla:16474. Bawolff 00:50, 1 March 2011 (UTC)Reply[reply]

Unfortunately, for some reason that I have been unable to fathom, the <DPL> tag doesn't work on my wiki. Or on my 1.16 test wiki. So something has changed between 1.15 and 1.16 which has broken that (but my PHP knowledge is far too limited to even attempt to figure out what). Even Using {{#tag:DPL doesn't work... Oh well, guess I'll have to live with it for the moment. --AerosAtar 20:26, 3 March 2011 (UTC)

Breaks when using ordermethod pagesel edit

I've run into an interesting problem. When attempting to generate a list using "linksfrom" and setting ordermethod to "pagesel", the parser breaks with the following error:

SELECT DISTINCT `page`.page_namespace as page_namespace,`page`.page_title as page_title,`page`.page_id as page_id, pagesrc.page_title as sel_title, pagesrc.page_namespace as sel_ns, CONCAT(pl.pl_namespace,pl.pl_title) AS sortkey FROM `pagelinks` as plf, `page`as pagesrc, `page` WHERE 1=1 AND `page`.page_is_redirect=0 AND `page`.page_namespace = plf.pl_namespace AND `page`.page_title = plf.pl_title AND pagesrc.page_id=plf.pl_from AND ((plf.pl_from=0)) ORDER BY sortkey ASC LIMIT 0, 500

Error message is:
Unknown column 'pl.pl_namespace' in 'field list' (localhost) 

What's interesting is that this error does NOT occur if I change "linksfrom" to "linksto". What's also interesting is that on a cursory check of DPLMain.php for malformed code and found that the column pl.pl_namespace isn't even referenced in the "linksfrom" section, but is referenced in the "linksto" section, but I may not be looking at it right.
   Thorncrag   20:50, 22 February 2011 (UTC)Reply[reply]

I forgot to post that I believe I found the issue causing this. On line 2088 of DPLMain.php the pagesel function is referencing the pagelink when it should be referencing pagefrom:
$sSqlSortkey = ", CONCAT(pl.pl_namespace,pl.pl_title) " . $sOrderCollation . " AS sortkey";

I changed pl.pl_namespace,pl.pl_title to plf.pl_namespace,plf.pl_title - and this seems to have resolved the issue.    Thorncrag   22:13, 16 March 2011 (UTC)Reply[reply]

Show images of a category including links to pages using these images! edit

Hi all,

I have a difficult question. I would like to create a gallery like that:


  |format=«gallery»,%PAGE%¦%NR%. %TITLE%\n,,«/gallery»


That works great. But now I would like to have the name of the page (all of my images are at least only used on one page!) which makes use of the image as image text (not TITLE). In addition to that the name of the page should be a linkt to the page! So it would be possible to show all Images of a certain category including linkt to each page using this image (there is only one page!).

Found this code here:




But I don´t know how to merge this two operations to one big thing!

Hope you understand what I mean :-).

Thanks in advance.

DPL for category page – order by second name? edit

I'm using DPL for a personalized category page because I didn't like the MediaWiki-own view. Everything works fine but there is one point I despair of. For the category of persons I want the list to be ordered by second name. In the standard category view this issue is solved by a tag on every page that tells MediaWiki how to order, e.g. on the page "Angie Gielach" [[Kategorie:Personen|Gielach]] to have it listed under "G" instead of "A".

In DPL I use the following code to display the pages of my category "Personen" alphabetically:

category = Personen
format   = ,\n* [[%PAGE%|%TITLE%]],,

Has anyone a solution for this? -- 20:57, 2 May 2011 (UTC)Reply[reply]

ordermethod=category,sortkey - IIRC it does't work well. --Subfader 21:25, 2 May 2011 (UTC)Reply[reply]

Compatibility with the Collection extension edit

This extension is great but when you try to export to a pdf with the book/collection extension nothing gets printed. Is there a way to solve this?--Tsouchon 13:50, 6 May 2011 (UTC)Reply[reply]

This is an issue with several extensions. See bugzilla:21653 for example. Bawolff 20:05, 24 May 2011 (UTC)Reply[reply]

Selecting Articles based on template parameter value edit

--Riveraea 20:10, 23 May 2011 (UTC) Hi, I am new to DPL. I have articles with a template named ProjectInfo, that contains parameters named ProjectName, ProjectOwner, ProjectDate. I want to use DPL to create a list of projects that are recent (ProjectDate less than 3 years old).Reply[reply]

I am testing this code:

 includematch = (Here I want ProjectDate > 3 years)
 resultsheader=Number of data = %PAGES%\n
 noresultsheader= no matching projects were found.\n

Thanks for any help!

You have to use a subquery which will result in all pages with the temnplate being returned but hiding those which do no match your age criteria (for which you'll need Extension:ParserFunctions for the check). A very dirty solution tho. --Subfader 19:04, 24 May 2011 (UTC)Reply[reply]

--Riveraea 19:36, 24 May 2011 (UTC) The logic I may use to evaluate the date is :Reply[reply]

{{#ifexpr:{{#time:U}} > {{#time:U| {{{ProjectDate}}} + 3 year}}|Older than 3 years|Less than 3 years}}

Do you mean that all the records may be selected, then format the output to hide not wanted records? Please provide an example of the format expression. Thanks!

Intercept a list of articles by alphabetic character edit

I have a list of articles on people, sort by last name (via sortkey). To make it easier for users to find a name in the list I want to intersect the list with subheadings showing the alphabetical character:

A edit

  • Otto Ader
  • Anton Albers

B edit

  • Chris Bill


Any ideas? -- 20:42, 1 June 2011 (UTC)Reply[reply]

It works this way
Should also work with mode=category
but I get a blank page on that (old DPL version here). http://semeb.com/dpldemo/index.php?title=Mode#mode --Subfader 18:26, 5 June 2011 (UTC)Reply[reply]

Thanks for your answer. I now use this:


Together with the setting ExtDynamicPageList::$categoryStyleListCutoff = 400; it outputs a list separeted by the alphabetical character but without columns. Now there is one new problem appearing: Somehow the parser doesn't change the html-tags produced by the DPL-plugin into wiki-links. Thats what I get:

A edit

  • <html><a href="/index.php/Otto_Abetz" title="Otto Abetz">Otto Abetz</a></html>
  • <html><a href="/index.php/Alma_de_l%27_Aigle" title="Alma de l' Aigle">Alma de l' Aigle</a></html>
  • <html><a href="/index.php/Helmut_Amanshauser" title="Helmut Amanshauser">Helmut Amanshauser</a></html>

Of course everything works well if I set $wgRawHtml = true; in localsettings.php, but shouldn't it work without this? -- 19:53, 5 June 2011 (UTC)Reply[reply]

No idea, never happened to me. But yes, it should work without $wgRawHtml = true;. For proper support you may want to start an "issue" on http://semeb.com/dpldemo/index.php?title=Extension_DPL --Subfader 19:03, 6 June 2011 (UTC)Reply[reply]

Problems with VariableExtension edit

I'm having problems with using the VariableExtension together with DPL, here is an example:

 {{#vardefine:pagetitle|Main Page}}



I'm using Mediawiki v1.17, Extension:VariableExtension v1.3, and DPL v1.8.9 (the MW1.17 build, DynamicPageList-MW1.17-r76531.tar.gz).

The output from the first call is not the same as the output from the second call. Shouldn't it be identical? The first call returns "Main Page" and "Talk:Main Page" as expected, but the second call instead gives this strange error message:

Extension:DynamicPageList (DPL), version 1.8.9 : ERROR: No selection criteria found! You must use at least one of the following parameters: category, namespace, titlematch, linksto, uses, createdby, modifiedby, lastmodifiedby or their 'not' variants

Please help! Amerias 13:27, 11 July 2011 (UTC)Reply[reply]

I have reported this above already, but now I looked into it a little bit further. Seems like this is a problem ob DynamicPageList. This extension shouldn use Parser::parse(), the code Parser class documentation states that this function should NOT be called recursively! Since this function is called for page rendering, you shouldn't use it within this extension. Instead you should use Parser::recursiveTagParse(). File: DPLMain.php, line 3310, $parserOutput = $localParser->parse( $output, $parser->mTitle, $parser->mOptions ); --Danwe 00:18, 24 July 2011 (UTC)Reply[reply]
I've tried to use recursiveTagParse as you suggested, but it doesn't fix the problem unfortunately. So far, I can confirm on 1.17 that this problem breaks Cite, Variables and Semantic Internal Objects behaviors. Everything is fine once DPL is deactivated.
sure you have changed it everywhere? Or there must be any other cause which is triggering the ParserClearState hook, thats the only event all variables getting flushed down the toilet... --Danwe 17:34, 30 July 2011 (UTC)Reply[reply]
I indeed changed it in multiple DPL files, but no success. As I saw on bugzilla, this bug is unfortunately here since 2009. -- 08:41, 31 July 2011 (UTC)Reply[reply]
It works in latest DPL, but latest DPL has different problems - "namespace" support doesn't work
If you still run into similar problems, I suggest you use #dplvariable instead of the #variable parser function.
The "namespace" support should still be working; the only thing that has changed is the fact that instead of "namespace = Article" you'll have to use "namespace = ". --Theaitetos (talk) 13:30, 22 March 2012 (UTC)Reply[reply]

Can't get a simple List to generate something other than HTML tags around the list contents edit

I've followed the install as stated and generated a simple test list which yields results with html tags around the list contents. I've tried it with both the DPL tag and the DynamicPageList tag and they still both output html and not wiki links.





    <html><a href="/index.php?title=Category:Camarilla" title="Category:Camarilla">Category:Camarilla</a></html>
    <html><a href="/index.php?title=Category:Vampire_Character_Creation" title="Category:Vampire Character Creation">Category:Vampire Character Creation</a></html>
    <html><a href="/index.php?title=Category:Vampire_Commentaries" title="Category:Vampire Commentaries">Category:Vampire Commentaries</a></html>
    <html><a href="/index.php?title=Category:Vampire_Policies" title="Category:Vampire Policies">Category:Vampire Policies</a></html>
    <html><a href="/index.php?title=Category:Vampire_Systems" title="Category:Vampire Systems">Category:Vampire Systems</a></html>

    <html><a href="/index.php?title=Category:Camarilla" title="Category:Camarilla">Category:Camarilla</a></html>
    <html><a href="/index.php?title=Category:Vampire_Character_Creation" title="Category:Vampire Character Creation">Category:Vampire Character Creation</a></html>
    <html><a href="/index.php?title=Category:Vampire_Commentaries" title="Category:Vampire Commentaries">Category:Vampire Commentaries</a></html>
    <html><a href="/index.php?title=Category:Vampire_Systems" title="Category:Vampire Systems">Category:Vampire Systems</a></html>
    <html><a href="/index.php?title=Category:Vampire_Policies" title="Category:Vampire Policies">Category:Vampire Policies</a></html>

    <html><a href="/index.php?title=Player_Page:Article_Count_Test2" title="Player Page:Article Count Test2">Player Page:Article Count Test2</a></html>
    <html><a href="/index.php?title=Player_Page:Article_Count_Test3" title="Player Page:Article Count Test3">Player Page:Article Count Test3</a></html>

    <html><a href="/index.php?title=Player_Page:PC_Census" title="Player Page:PC Census">Player Page:PC Census</a></html>
    <html><a href="/index.php?title=Player_Page:Player_Pages" title="Player Page:Player Pages">Player Page:Player Pages</a></html>

    <html><a href="/index.php?title=Player_Page:Sandbox" title="Player Page:Sandbox">Player Page:Sandbox</a></html>

I'm running MW 1.16.2 with PHP 5.2.17 (cgi) and MySQL 5.0.91mm-log

Have I forgotten something? I put in the following on my localsettings.php and downloaded from the extension page the proper package for my version of MW.


I don't know where else to go for help. I've reviewed bugs and issue pages and really didn't see anything applicable. I even tried to install the Wikimedia version of this extension and that worked fine (although that version doesn't have all the function I want so I'd rather have this one.) Please help. --Thing 1 23:44, 30 August 2011 (UTC)Reply[reply]

I am on a 1.16.2 install. I found that the trunk version worked and not the 1.16.x version. --Thing 1 04:39, 31 August 2011 (UTC)Reply[reply]

Try to set $wgRawHtml to true. --Theaitetos (talk) 13:33, 22 March 2012 (UTC)Reply[reply]

Variables edit

Is there a conflict between this and Extension:Variables? In particular, it seemed that DPL was blanking variables, causing an error message like this, and it was resolved by having the DPL variable declared first before the total variable (like this). --Sigma 7 17:07, 27 September 2011 (UTC)Reply[reply]

You can also try to use the #dplvariable function when working with variables and DPL calls. --Theaitetos (talk) 13:34, 22 March 2012 (UTC)Reply[reply]

Question about "includematch" edit

I use this great extensions in two of mine wikis. In the last times, i have some problems with includematch. My Wiki is about Final Fantasy XIV Online, for info ;)

NPCs are selling some Items, the item goes in the category:example sells from NPC. Now, some NPCs sells example-head, examplefeed, example-earring. If i create now the Article examlpe, i use this DPL:

|category = {{SUBPAGENAME}} sells from NPC
|namespace =
|includepage = {Sellsrow}:Price, {NPC} dpl Zones
|includematch =  /\s*Item\s*{{=}}\s*{{fixapos|{{fixtick|{{fixparen|{{SUBPAGENAME}}}}}}}}/si
|format      =,,\n
|table       =class="SE-Heaventable sortable" style="width: 100%;",Name,Preis,Region
|rowcolformat= style="background-color: transparent; width: 100%;"
|tablerow = %%,%%

Here i use the _Template:Sellsrow to get the Price and the Template:NPC dpl Zones to get all other datas. In the Template:Sellsrow, i define Item. Thats why my includematch say get where Item = {{SUBPAGENAME}}. So, my Articles shows me now in the Table all sellinginformations about:

  • example
  • example-head
  • examplefeed
  • example-earring

i try'd some other includematch variations like this:

|category = {{#if: {{{Name|}}}|{{{Name|}}}|{{PAGENAME}}}} sells from NPC
|namespace =
|includepage = {Sellsrow}:Price, {NPC} dpl Zones
|includematch =  /\s*Item\s*{{=}}\s*{{#if: {{{Name|}}}|{{{Name|}}}|{{PAGENAME}}}}/si
|format      =,,\n
|table       =class="SE-Heaventable sortable" style="width: 100%;",Name,Preis,Region
|rowcolformat= style="background-color: transparent; width: 100%;"
|tablerow = %%,%%

but at least, i have allways the Same problem. It shows me all what that NPC have, where example is in :\ The only what i want to see, is the Data for example >.< Someone knows how i can fix it? Yukii 12:52, 17 October 2011 (UTC)Reply[reply]

I'm not quite sure I understood everything you said, so in case you want to clarify, you can tell me in German. // Ich bin mir nicht ganz sicher, dass ich alles richtig verstanden habe, und falls nicht, dann kannst du es gerne auf Deutsch nochmals erklären.
The problem is, as far as I can see, that you never included the line "Item=..." in your DPL call; you only called to include "Price=..." parameter in the {Sellsrow} template. The includematch function works only, if you include the respective parameter, so in order for it to work, you need to change {Sellsrow}:Price to {Sellsrow}:Item:Price. --Theaitetos (talk) 13:43, 22 March 2012 (UTC)Reply[reply]

Warning about $maxResultCount edit

Just as a heads-up, $maxResultCount is not a limit on DPL's results, but a limit on the amount of rows pulled from the database. That is not the same thing. For example, the DPL query...


...will first pull all pages beginning with "Foo" in the category "Foos" from the database, and only then check for the includematch pattern. In other words, if $maxResultCount is 500 and you have 800 Foo% pages in the Foos category, even if just ten of those match your includematch pattern, you will probably not get all ten.

Our solution was to remove the limit entirely ($allowUnlimitedResults = true), because our wiki is private and we have a strong control over authorship.

Your mileage may, of course, vary. -pinkgothic 13:32, 30 November 2011 (UTC)Reply[reply]

Does not work with mediawiki 1.18 edit

On upgrade from mediawiki 1.65 to 1.18, DPL stopped working. I downloaded the latest version from Semeb website. But still does not work. The error is:

Fatal error: Call to a member function addMessages() on a non-object in xxxxxx/extensions/DynamicPageList/DPLSetup.php on line 1163

Help! Jonathan3 00:49, 11 December 2011 (UTC)Reply[reply]

Try this... find the error line and it should be this piece of code or something similar:

        foreach( DPL2_i18n::getMessages() as $sLang => $aMsgs )
            $wgMessageCache->addMessages( $aMsgs, $sLang );

In MW 1.18 $wgMessageCache is deprecated so just comment out all those lines. It should work ok after that. --Paracelsus 22:50, 12 December 2011 (UTC)Reply[reply]

But that won't add the messages to the cache... --Subfader 08:04, 13 December 2011 (UTC)Reply[reply]
Better question is wtf is the extension doing messing around with the message cache by hand... Bawolff 19:21, 13 December 2011 (UTC)Reply[reply]
I commented out those lines. Now it gives me the following error: Fatal error: Call to private method Title::prefix() from context 'DPLMain' in xxxxx/extensions/DynamicPageList/DPLMain.php on line 2631. What next? :-) Jonathan3 22:34, 18 December 2011 (UTC)Reply[reply]
I also commented out the following lines:
            if ($bShowNamespace)
                //Adapted from Title::getPrefixedText()
                $sTitleText = str_replace( '_', ' ', $title->prefix($sTitleText) );
I'm not sure if everything works fine now, but at least the error message disappeared -- 21:34, 25 December 2011 (UTC)Reply[reply]

*FIXED* Removing the lines above fixed it. I also found the following page which may be of interest (and which includes a replacement for the missing lines): Special:Code/MediaWiki/86335 Thanks everyone Jonathan3 23:15, 27 December 2011 (UTC)Reply[reply]

I only saw a replacement for the second set of lines you had comment out, is that correct? Also, does this them restore the adding messages to the cache? Thanks! Ncarty97 16:36, 26 January 2012 (UTC)Reply[reply]

2012 edit

Null edits (or dummy edits) required for updating DPL listing edit

The wiki I administer makes a huge use of DPLs for constructing lists of pages and controlling workflows--very well might I add.

One problem that I have perennially run into however is the need to execute a null edit in order for pages to properly show up in a DPL when the DPL is grabbing based on, for instance, page category. What I don't understand is that when accessing the page in question the category is correct, but the DPL listing the page will not include the page in its list until executing a null edit on the page. I'm fairly knowledgebale about this extension but I have not come up with a solution to this problem. I've even tried using updaterules to "touch" the page when the list is built, but that feature does not seem to be usable at this point.

Since the page shows the correct category, and the job queue is empty, I can't actually figure out why this is happening. The only thing that I can think of is that the DPL is stored in a cache; however, that should not be causing this since cached results are supposed to be disabled by default. I do have MediaWiki parser cache set to enabled as well as file cache, but disabling these seems to have no effect on the symptom. Any thoughts on this?    Thorncrag   18:40, 12 January 2012 (UTC)Reply[reply]

I may have posted too soon; I completely disabled caching across the wiki and this seems to have resolved the problem altogether. This works for now, although from a scalability perspective I'm not sure.    Thorncrag   19:20, 12 January 2012 (UTC)Reply[reply]
I think I posted too soon again. I think disabling cache only caused an update, but null edits are still required. I can't seem to find a way around this.    Thorncrag   16:39, 1 February 2012 (UTC)Reply[reply]
Have you tried to purge the page with the DPL call? --Theaitetos (talk) 13:46, 22 March 2012 (UTC)Reply[reply]

"skipthispage" - not bolded when created by DPL edit

Hi! I'm working through the book MediaWiki and Beyond. Great book, but I've run into something that doesn't seem to be working. In the book it says that if you use the 'skipthispage' variable and set it to false, not only will the page you are on show up in your list (in this case a navigation list), but since its pointing to itself, it will default to bolded text rather than a link. I don't seem to be able to get that behavior though. If I put a link to the page within itself, that will bold and present just as text, but not when it comes through the dpl command. Any ideas why? Thanks! Ncarty97 20:41, 1 February 2012 (UTC)Reply[reply]

Confirmed. Never worried about it tho. --Subfader 23:39, 1 February 2012 (UTC)Reply[reply]
It works fine for me. Could you give some more information (version MW and DPL?) and show me an example of the issue? You can do so on the DPL wiki if you want to. --Theaitetos (talk) 13:53, 22 March 2012 (UTC)Reply[reply]

Redirects not showing DPL listing edit

Similar to above, the DPL listing is not showing up when you go to the page via redirect. So when you "null edit" it then works. Any clue on why this may be happening?

Here is the error message: Extension:DynamicPageList (DPL), version 1.8.9 : Warning: No results.

Thanks, CJL108 00:35, 15 February 2012 (UTC)Reply[reply]

Hello, could you clarify the issue a bit? I'm not sure what exactly you mean with redirects not showing up. Have you tried setting the redirects parameter to include? --Theaitetos (talk) 13:55, 22 March 2012 (UTC)Reply[reply]

Security issues? / Version 2 edit

What exactly needs to be fixed to resolve the security issues? Are they resolved in version 2? And what needs to happen before version 2 is released? Guaka (talk) 13:16, 16 February 2012 (UTC)Reply[reply]

Bit of useful info at User talk:Pinkgothic/DPL#Caching sidenote (this page is a good read altogether :) Guaka (talk) 13:53, 16 February 2012 (UTC)Reply[reply]

DynamicPageList only works with global $wgRawHtml set to true. edit

Between MediaWiki version 1.15 and 1.16 the way the < html > tag is handled changed. As a result, the DynamicPageList extension's abuse of the global $wgRawHtml setting to temporarily enable raw HTML content is broken. The normal way (to my knowledge) for an extension developer to embed raw HTML is to create one or more markers and then to post process the content and replace the markers with HTML after MediaWiki has done all of it's HTML stripping. 22:53, 4 March 2012 (UTC)Reply[reply]

That is correct. To anyone interested See the docs for the StripState class (which extensions can use to insert strip items that will be automatically unstripped by mediawiki at the apropriate time). Bawolff (talk) 19:05, 13 June 2012 (UTC)Reply[reply]

multiple notitlematch using {#dpl} edit

I have my query running fine if I used <DPL> to exclude multiple pages, but I need to run it using {{#dpl}}. How do I exclude multiple pages here when the | delineates query parameters?

nottitlematch=A|B|C -> fails, "expecting =" error
nottitlematch=A\|B\|C  fails, "expecting =" error
nottitlematch=A,B,C fails
nottitlematch=A;B;C fails

nottitlematch=C only excludes the last one

As usual, when you use a parser function, you will have to use {{!}}, when you want to denote a "|" without making a statement about a new parameter (see here):
nottitlematch = A{{!}}B{{!}}C
Ofc you need to define the Template:! as usual.
--Theaitetos (talk) 21:23, 9 April 2012 (UTC)Reply[reply]
Thx for the prompt response, works perfectly.

WantedPages, Templates, Files, and Categories edit

Hi. I was wondering if it is possible to use DPL to create the list of Wanted Pages, Templates, Files, and Categories. My wiki uses this already for anything that isn't uncategorized, so we can categorize it immediately. I would like to do the same for Wanted Pages, Templates, Files, and Categories. Is this possible, and how would I do that? 17:18, 11 June 2012 (UTC)Reply[reply]

You have special pages that list wanted pages, templates and files already. Why exactly do you need DPL to create those lists as well? Aside from that, no, I don't think that is possible. --Theaitetos (talk) 18:08, 12 June 2012 (UTC)Reply[reply]
To keep it up-to-date and so it can be fixed faster than those pages can update. 16:31, 13 June 2012 (UTC)Reply[reply]
If you're using DPL, performance obviously isn't a concern, so don't use $wgMiserMode, and those pages will be updated instantly. Bawolff (talk) 19:01, 13 June 2012 (UTC)Reply[reply]

Allowcachedresults WARNING edit

It does not display!
I set:

$wgFileCacheDirectory  = "$IP/cache"; 
$wgShowIPinHeader      = false;  
$wgUseFileCache        = true;

And I set the Template:DPL Cache Warning, but the message won't display. Any ideas? - 19:50, 18 June 2012 (UTC)Reply[reply]

The allowcachedresults refers to the parser cache, which is different from the File cache (and as such, settings related to the file cache really don't have that much bearing on how allowcachedresults should work [afaik]. Of course, disabling parser cache would also disable file cache so they're mildly related, but I would concentrate first on verifying that parser caching is working [ which it does appear to be based on the <!-- Saved in parser cache with key guildwar_wiki:pcache:idhash:2870-0!*!0!!pt-br!2!edit=0 and timestamp 20120619120119 --> from the link). Bawolff (talk) 12:10, 19 June 2012 (UTC)Reply[reply]
Please... someone help me, I don't know what else I can do, another thing that happens is that the following template call makes pages show AS templates (when previewing):
|category=*Skills do elementalist¦Skills downed¦Skills de Lava Axe¦Skills de Magnetic Shield¦Skills de Fiery Greatsword¦Skills de Bow of Frost¦Skills de Lightning Hammer
|uses=Predefinição:Skill infobox
|include={Skill infobox}:%PAGE%,{Skill infobox}:description,{Skill infobox}:%PAGE%,{Skill infobox}:recharge
|secseparators = ²{#vardefine:,¦,,}²,²{#vardefine:Recharge-,¦,,}²

The template is called in this page. - 21:51, 18 June 2012 (UTC)Reply[reply]

I'm not sure if I got what I'm supposed to do, also, the resultsheader = %PAGES% isn't working. 07:06, 9 August 2012 (UTC)Reply[reply]

Where can I download DPL2? edit

First, I don't know git very well but it seems that all of the links to download DynamicPageList2 are broken. Can anyone point me to a version of DPL2 that works with MediaWiki 1.19? Thanks.

http://semeb.com/dpldemo/index.php?title=DPL --Subfader (talk) 22:13, 29 June 2012 (UTC)Reply[reply]
I doubt this extension has been migrated to git since no one has been maintaining it for years. The svn links should still work. Bawolff (talk) 01:32, 3 July 2012 (UTC)Reply[reply]

Attempting to use DPL to create a table "on-the-fly" on any given article page by pulling from a list on a page; Getting error message: %DPL-1.7.6-WARNING: No results! edit

  • Hi, so my goal in this scenario is to create a table on-the-fly using DPL and put that table on any given article page (I've opted to do a template call to facilitate this) -- and so part of the problem has been to figure out which of the DPL commands are best suited to accomplish this. I started with table and tablerow and initially got the results I was looking for on simpler test examples. But now I'm getting this error %DPL-1.7.6-WARNING: No results! and I can't find my bug! So yesterday I started looking at the secseparators and multisecseparators commands, but the syntax is killing me and they're just a bit too tricky for me right now (I just started learning/implementing DPL). In the DPL Manual it even suggests sticking with "table" and "tablerow", and that's what I'd like to do.
  • I'd be grateful for some help figuring out where I took a wrong turn.
  • One thing I saw yesterday was that I had misnamed the first parameter - i.e., Drug Code instead of Pfizer Drug Code. So I corrected that. It still didn't work. So I created a new Template:Drug Info 5 and Template:Drug Info5.dpl - suspecting that maybe there was something I wasn't aware of in the functioning of a phantom template where even if I fixed the parameter name in the dpl template, the phantom template might not pass the parameters through properly (?).
  • Further down I list an example that did work. That's the one I built upon to try to get this one to work.
  • Many thanks for your reply and insight. Cheers, Jeff Western cell: 323.449.7944

Full error message is:

%DPL-1.7.6-WARNING: No results!
{|class="wikitable collapsible collapsed sortable"
!Pfizer Drug Code !Drug Brand Name !Compound Name !Drug Class !Project Code |} 

Here's the DPL and template call which goes on any given article (page):

|linksto=:EQDD Pfizer Compounds (to assoc drugs to Ulcerative Colitis) 
|include = {Drug Info 5}.dpl
|table   = class="wikitable collapsible collapsed sortable",-,Pfizer Drug Code,Drug Brand Name,Compound Name,Drug Class,Project Code
|tablerow = %%,%%,%%,%%,%%,

Here's Template:Drug Info 5.dpl:

{{{Pfizer Drug Code|}}}
{{{Drug Brand Name|}}}
{{{Compound Name|}}}
{{{Drug Class|}}}
{{{Project Code|}}}

And then there's the phantom Template:Drug Info 5 which just serves to pass the above 5 parameters.
The article:EQDD PFizer Compounds (to assoc drugs to Ulcertative Colitis) -- has a small listing of just a few drugs for me to test out the DPL, for example:

{{Drug Info 5|Pfizer Drug Code=PF-00547659|Drug Brand Name=drug brand name|Compound Name=compound name (for Ulcerative Colitis, Crohn's Disease)|Drug Class=null|Project Code=A728}}

WORKING VERSION which did create a table on-the-fly successfully:

|linksto=:EQDD for UK-092480  <-- but strangely, when I replaced UK-092480 with PF-00346519 (which is what it should be) it craps out
|include = {Drug Info 3}.dpl
|table   = class="wikitable collapsible collapsed sortable",-,Drug Code,Drug Brand Name,Compound Name,Drug Class,Project Code,Description,Disease
|tablerow = %%,%%,%%,%%,%%,%%,%%,

Previously I also tried to put the Drug Info parameters for each drug beneath a Drug Code section heading. Then, using #1sth:, I was able to get the Drug Info parameters -- but I couldn't figure out how to parse out the individual drug parameters in order to then output them in tabular format and build that table on-the-fly. Here's what I'm talking about:

  • Inserting the <onlyinclude> transclusion section tag into the data source (page):
<onlyinclude>{{#ifeq:{{{transcludesection|Pfizer Drug Code}}}|Pfizer Drug Code|PF-00547659}}</onlyinclude><br>
drug brand name <br>
compound name (for Ulcerative Colitis, Crohn's Disease)<br>

Getting the "UK-092480" Drug Info parameters from the data source using template code only, {{#lsth:(page)|(parameter)}}:

{{#lsth:EQDD for UK-092480|Drug Code}}
{{#lsth:EQDD for UK-092480|Drug Brand Name}}
{{#lsth:EQDD for UK-092480|Compound Name}}
{{#lsth:EQDD for UK-092480|Drug Class}}
{{#lsth:EQDD for UK-092480|Project Code}}
{{#lsth:EQDD for UK-092480|Drug Description}}
{{#lsth:EQDD for UK-092480|Disease}}
Hi, could you give me a link to your wiki and the respective pages, so I can take a look at it? --Theaitetos (talk) 23:24, 4 July 2012 (UTC)Reply[reply]
Hello, I wish I could give you a link to the wiki, but it's an internal wiki to the company and a network credentials are required in order to even view the wiki. Good news is that the solution to this first part of my problem is to use titlematch= in the DPL, not linksto=. I admit, I really didn't quite understand how the linksto command works, but titlematch definitely worked.
 | titlematch=EQDD_Pfizer_Compounds_(to_assoc_drugs_to_Ulcerative_Colitis) 
 | include = {Drug Info 5}.dpl
 | table   = class="wikitable collapsible collapsed sortable",-,Pfizer Drug Code,Drug Brand Name,Compound Name,Drug Class,Project Code
 | tablerow = %%,%%,%%,%%,%%,
I'm currently trying to figure out how to use the output of this table to enable the end-user to pick a drug (a row of Drug Info data) and copy that row and only that row to a new table in another section of the same page. I was going to upload an image here so you could see what the table looks like, and where I'm trying to get to... but I don't see an Upload link here.
I appreciate your having looked at my questions, in any case. Thank you!
You could upload files via Special:Upload, but I recommend uploading to an image hoster like http://tinypic.com or something similar.
I am still a bit unsure what you mean with copying that code to the same page. Are you trying to create a table, or code for a table that can be copied and pasted?
The tablerow in the latest statement shouldn't do anything as the entire output of a phantom template should not be changed by tablerow.
The linksto statement is selecting pages basically the same way as the "what links here"-tool.
The way you use the titlematch statement should only give you one page, the very one you put into the statement. If you want to select several pages with titematch, you will have to use "_" as a one letter wildcard or "%" as a wildcard for any amount of letters; for example "titlematch=c_t" would give you "cat", "cut", et.al. yet "c%t" could even give you "cannot", "carrot", ...
--Theaitetos (talk) 20:34, 5 July 2012 (UTC)Reply[reply]
I am trying to create a table which will contain only the drugs (Drug Info in each row) that the user has selected from a master list (a table of ALL drugs). I'm really perplexed how to do this!
I don't think you need a phantom template at this point. In order to create such a table, just try the following code:
  |uses = Template:Drug Info 5
  |include = {Drug Info 5}:Pfizer Drug Code:Drug Brand Name:Compound Name:Drug Class:Project Code
  |table = class="wikitable collapsible collapsed sortable",-,Pfizer Drug Code,Drug Brand Name,Compound Name,Drug Class,Project Code
--Theaitetos (talk) 00:24, 7 July 2012 (UTC)Reply[reply]
Theaitetos, I much appreciate your looking at this and answering with this code. I just tried it and it works. I got my code with the phantom template to work as well, but yours is a bit cleaner of course. I do get some multiple hits on a couple of the drugs, not sure why, but I suspect it might be my error somewhere (maybe too many category tags?!); I also got multiple hits with my code.
(7/12/12)On another note, the last piece of the puzzle for this first User Story that I'm trying to solve right now is this... Once the user is on a Disease page, how do I "automate" (from the user's pov) the selection of drug(s) that they wish to associate with the disease? (...which then leads to the creation of the on-the-fly-dpl-table, which is pretty much working now -- thanks again!) So, I've checked with the internal IT dept here, and Javascript drop-menus are out of the question -- too bad, seems that's the nicest way to implement this. Raw HTML is not allowed currently on the company's internal wiki (and discouraged in general), and Javascript is only allowed by changing Common.js – which is a javascript which is triggered on every page load on the wiki. So they're telling me it's very inefficient to include Javascript on their internal wiki. Okay, so the approach I just hit on yesterday (brainstorming in my head while smoking a cigar!) is to do the following:
  • Created a template: {{DPL for EQDD Diseases List with include redirects}}
  • This template has DPL: {{#dpl: |category=EQDD Diseases List |mode=none |redirects=include |format=,\n* EQDD for [[%PAGE%|%TITLE%]],, }}
  • Then I do the template call on any Disease page where I need it and it works, producing:
EQDD for Age Related Macular Degeneration
EQDD for Allergy and Respiratory
EQDD for Asthma
EQDD for Bunionectomy
EQDD for Chronic Abacterial Prostatitis
EQDD for Crohn's Disease
EQDD for Crohn’s Disease
EQDD for Dental Pain
EQDD for Discoid Lupus
EQDD for Endometriosis
EQDD for Inflammation
EQDD for Lupus
EQDD for Lupus Nephritis
EQDD for Male Erectile Dysfunction (MED)
EQDD for Ophthalmology
EQDD for Pain
EQDD for Primary Dysmenorrhea
EQDD for Systemic Lupus Erythamatosus (SLE)
EQDD for Ulcerative Colitis
EQDD for Women's Health and Urology
  • But here's is where I run into a stumbling block... I've discovered that when I try to run the subst: command on dpl, I just can't get it to substitute the straight text for me, e.g., {{subst:{{DPL for EQDD Diseases List with include redirects}} }}. What it does is always gives me the dpl in the substitution. What I need I think! is the straight text so that I can manipulate it. Because clearly, one cannot manipulate the output from a template call, or DPL, as it is just for viewing, right. So unless there is a way, using DPL commands, to further manipulate the data (on-the-fly by the DPL) such that a user can somehow select one of the diseases (list above) -- then I don't see any other way to do this. I suppose they could just highlight the text in the page name (from the list above), copy it, and paste it into a link on that Drug page, e.g., [[EQDD for Ulcerative Colitis]]
  • You see, what I'm trying to do is a work-around to not having a drop-down menu option for folks to be able to select from a list of already existing Disease pages. This way, they cannot possibly enter the name of the Disease page incorrectly. So what I'm trying to do is figure out a way to take a Disease page name (exactly as you see them listed above) and turn that page name into a [[link]] on the drug page -- thus the association between the drug and the disease. Then I use the linksto= command, and I get a listing of just the drugs that have been selected and associated with a disease, displayed by the on-the-fly-dpl-table on the Disease page. Again, any suggestions would be greatly appreciated. Thank you.
  • As far as javascript is concerned: There should be some javascripts coded into the core Mediawiki css anyway, so you could try to use that stuff to do some drop-down menus. For example, try to see if the following table works in your wiki:
  • Thank you for this great suggestion! This would be a terrific solution but unfortunately it doesn't run on the company's internal wiki. I'm thinking they don't have any Javascript enabled..? When I put this table into the internal wiki, it builds a table just fine, but it's not interactive (won't expand, collapse) like it does here.
Headline 1 Headline 2 Headline 3
Cell 1-1 Cell 1-2 Cell 1-3
Cell 2-1 Cell 2-2 Cell 2-3
Cell 3-1 Cell 3-2 Cell 3-3
  • As for the substitution: You have to substitute a dpl-call by adding the "subst:" into the dpl-call, i.e.: {{subst:#dpl:
  • That's AWESOME! Thank you -- just tried it and it works great! You see, what I'm after is implementing a User Story where the goal is associate a drug with a disease and in order to do this, I must ensure the end-user cannot enter a link incorrectly... ergo my interest in drop-down menus! Shame they won't work on this company's wiki. Anyway, so my work-around is to grab all the disease pages (they're tagged by Category of course) and then wrap [[..]] square brackets around the disease page name (article name) and then instruct the end-user to copy that text exactly (with the brackets) and paste it into the Drug page. So that creates the link, which linksto= then uses to pull up only those Drug pages that have been associated with a particular Disease page. Of course down the road, it would be nicer to have that [[link]] get inserted in a more automated fashion -- to avoid any possibility of the user making a mistake.
  • It's hard to imagine what output you specifically desire without looking at it. Could you put one example down here, so I can see it? I.e. the direct output you desire, no dpl anything, just how you want it to look like and I'll see if I can find the proper code to produce said output.
  • Yes, I can appreciate that. That's why I wear multiple hats on this job - Business Analyst, to understand their needs and document requirements - Developer, to implement the User Stories - and PM to hopefully make all this happen in time. So next week I'm going to set about updating my User Story diagrams and I'll start with this user story, and I'll list it here for you to see. Again, many many thanks for your great suggestions. It's been a hard week -- what with going down blind alleys with subst: -- and your hint will I think get me there!
  • About having multiple results: You can disable multiple results by adding the parameter distinct = strict to your dpl call.
--Theaitetos (talk) 23:51, 12 July 2012 (UTC)Reply[reply]

Are MediaWiki 1.19.1 and DPL incompatible? edit

I tried to use DynamicPageList 1.8.9 with MediaWiki 1.19.1 with no success. I have used for a long time DPL with MediaWiki 1.16.5. Does someone use DPL with MediaWiki 1.19.1 without any problems?

Yes, there are Wikis that are running DPL with Mediawiki 1.19, e.g. this wiki. Have you set $wgRawHtml to true? --Theaitetos (talk) 20:09, 6 August 2012 (UTC)Reply[reply]
Many thanks for your reply Theaitetos. Yes, I have set $wgRawHtml to true. I went to the http://www.wiki-aventurica.de/wiki/Spezial:Version page and I saw that there is the Version 2.0 of DynamicPageList installled on this wiki. However as far as I know the last version of DPL is 1.8.9. Is this a special version? Anyway, I will try to use DPL tomorrow with MediaWiki 1.19.0.
I tried to install DPL 1.8.9 with MediaWiki 1.19.0 again with no success. I have added
$wgRawHtml = true;

in the LocalSettings.php file. When I try a simple query e.g.


I get the result "?UNIQ49ade83c2b3c89b7-dpl-00000001-QINU?". Any help is greatly appreciated!

Check the zip file in Download for DPL2. --Theaitetos (talk) 19:35, 9 August 2012 (UTC)Reply[reply]
Just for reference, the error "?UNIQ49ade83c2b3c89b7-dpl-00000001-QINU?" is caused by extensions recursively calling the parser (That doesn't help you much as a user, but in case you were wondering where the error was coming from). Bawolff (talk) 20:04, 9 August 2012 (UTC)Reply[reply]
Also, the zip file contains version 1.8.9 not 2.0. I'm also quite interested in version 2.0 because lots of people use this extension, and version 2.0 is claims to fix the various security issues. Alas the author's websites says the code is unreleased pending testing (but has said that for over a year). Bawolff (talk) 20:11, 9 August 2012 (UTC)Reply[reply]
Version 1.9 also seems to work with MW 1.19 and can be found here: https://svn.wikimedia.org/svnroot/mediawiki/trunk/extensions/DynamicPageList/
--Filburt (talk) 09:05, 11 August 2012 (UTC)Reply[reply]
Thank you very much Filburt for your suggestion! Version 1.9 works with MediaWiki 1.19 in my system (Moutain Lion, MAMP 1.9.6). Version 1.8.9 still does not work.

I will publish 2.0 soon, it will run on the latest MW version and avoid the security risks mentioned above. This will be my last and final action on DPL. I would be pleased if someone would like to keep the work up and put the new DPL into the official source code repository. (Gero, the author.) 22:21, 14 August 2012 (UTC)Reply[reply]

If you release the code, I'd be happy to put it in wikimedia's svn repo for you. (I'm not sure if there would be much point converting to git at this point though, since it appears its not going to really have an active maintainer). Bawolff (talk) 12:12, 15 August 2012 (UTC)Reply[reply]
Gero and me agreed on certain plans for the future: So I'll work myself into it and then actively maintain the extension. Bare with me, if it takes some time though, I am quite busy these days. --Theaitetos (talk) 14:30, 15 August 2012 (UTC)Reply[reply]
Cool! When you're ready you should probably ask for a gerrit account at Developer_access, and for DPL to be moved from svn->git at Git/Conversion/Extensions queue. (Of course moving to git is not a requirement, but 99% of all MediaWiki development seems to be moving to the git repo). Bawolff (talk) 14:44, 15 August 2012 (UTC)Reply[reply]
OK, I requested an account for now. Once everything is settled here, I ask for it to be moved to git. Any other advice you can offer me, as I haven't been involved in extension development so far? --Theaitetos (talk) 17:29, 15 August 2012 (UTC)Reply[reply]
Don't be afraid to ask questions. Also hang out in the #mediawiki irc channel on freenode, there's lots of friendly people there always willing to help (Not to mention one learns a lot just by eavesdropping on the conversations of others) [Of course I haven't been in #mediawiki in ages, so for all I know you could already be hanging out there). Bawolff (talk) 17:36, 15 August 2012 (UTC)Reply[reply]
As you surely have noticed DPL 2.0 has been released and can be downloaded. My agreement with Theaitetos says that I will assist him in finding bugs (if needed) whereas it is up to him to support users and add new features. Algorithmix (talk) 07:35, 20 August 2012 (UTC)Reply[reply]
BTW: There is also another "power user" of DPL (poke) whio is interested in maintaining DPL in future. Algorithmix (talk) 10:26, 20 August 2012 (UTC)Reply[reply]
Added to svn - rev:115677. The i18n people might not like some of the changes to the i18n files. I noticed there is an issue where links to pages in non-main namespace don't go to right namespace. Bawolff (talk) 18:37, 20 August 2012 (UTC)Reply[reply]

php Strict Standards error, MediaWiki 1.19.1 installed on xampp 1.8.0 edit

I recently installed MediaWiki 1.19.1 on xampp 1.8.0. Yesterday I added this extension and while the pages that call it do produce a list of pages very nicely, there is also an error:

Strict Standards: Only variables should be assigned by reference in D:\xampp\htdocs\mediawiki\extensions\DynamicPageList\DPLMain.php on line 2549

I am no php mediawiki or apache hotshot, but after searching it seemed likely that the issue was overzelaous error reporting by php.

In php.ini I changed

error_reporting = E_ALL | E_STRICT


error_reporting = E_ALL

and restarted apache. Then I completely rem'd that line. But the error message persists. Any suggestions?


Depending on your caching settings, the error could have been cached from before you changed the error reporting levels. Try Purging the page where the error happens. Sometimes people also change error reporting in LocalSettings.php (usually for debugging purposes, and then forget). Bawolff (talk) 19:01, 2 September 2012 (UTC)Reply[reply]
Thanks for the response. I purged the page and it didn't help. I have not adjusted error settings in LocalSettings.php; I don't see anything there about errors in fact. What else could it be? MichaelS
Try to remove the "&" in line 2549. Let us know here if this works. 05:01, 8 September 2012 (UTC)Reply[reply]
Hi, have the same problem, solution above mentioned works partially - the skin of wikimedia gets blown away by this - the top navigation bar is now floating on top as if the error message still would be show, only that it is now empty...
If you have version 2.01 of DPL the offending line can simply be deleted. The variable $sk is nowhere used. I suppose that you are using an older version. Please download 2.01 from mediawiki.org or from semeb.com/dpldemo. Algorithmix (talk) 06:25, 12 September 2012 (UTC)Reply[reply]
I've just downloaded version 2.01 from semeb.com/dpldemo (download from mediawiki.org doesn't work at the moment) and tested it with MediaWiki 1.20.0. This problem with line 2549 of DPLMain.php is still present, so apparently the line was not deleted from version 2.01. The same problem also exists for line 284 of DPL.php, which also invokes the variable $sk. I commented out both lines, it seems OK now. Maybe both lines should be deleted from the downloadable version. -- 08:39, 15 November 2012 (UTC)Reply[reply]

Using #titleparts to control the output of Subpages edit

First, great extension, glad to see it was updated! I need some help as I am having issues with subpage listing. If I use this:

format=,\n*[[%PAGE%|{{#titleparts: %TITLE%|1|1 }}]] {{footemplate|{{#titleparts:%TITLE% |1|2 }} }},,

Using the above, #titleparts parses just fine, all I see is the name of the parent page, exclude Foo/foo1/foo2 subpages, so all I get are the child links of the parent page, not the whole list of subpages. The first #titleparts, shows the parent name, and the 2nd #titleparts calls a template to and passes the child's name as a parameter, which adds a marker to note the page. It works great. So what is the problem? I want to call this as a template and you can't use titlematch={{PAGENAME}}/% unless you call dpl with:

|format=,\n*[[%PAGE%|{{#titleparts: %TITLE%|1|1 }}]] {{footemplate|{{#titleparts:%TITLE% |1|2 }} }},,}}

The list is made, but #titleparts is completely ignored in the parser call of dpl. Am I missing something? Any help appreciated because all I see is the full link to the subpage and the template call is completely ignored. Thanks Hutchy68 (talk) 12:17, 16 September 2012 (UTC)Reply[reply]

Here the correct code:
|format=,\n*[[%PAGE%¦ ²{#titleparts: %TITLE%¦1¦1}² ]] ²{footemplate¦ ²{#titleparts:%TITLE%¦1¦2}² }² ,,}}
When you use template calls in your dpl statement, you need to escape the templates with ²{ instead of {{ and instead of }}, otherwise dpl won't be able to pass variables to the included template. And you also have to escape | by using ¦, otherwise the following text will be interpreted as dpl-parameter. Also, instead of {{NAMESPACE}} use {{NAMESPACEE}} since space characters need to be given as uunderline scores to work correctly.
Yet, I wouldn't recommend the above code, as it is a lot more efficient to use the replaceintitle function of dpl, which allows you to have the %TITLE%-variable changed with a regular expression. Example, try this:
|format=,\n*[[%PAGE%¦%TITLE%]] ²{footemplate¦ ²{#titleparts:%TITLE%¦1¦2}² }² ,,}}
Here, I eliminate everything in the %TITLE%-variable behind the first /. The @ ... @ is just there to mark the beginning and end of the regex statement, you can also use other non-alphanumeric characters, but since @ is rarely ever used in any code at all (at least in the wikis I know), I go with @ as it stands out and can be more easily seen than slashes or something. --Theaitetos (talk) 13:38, 16 September 2012 (UTC)Reply[reply]
Thanks Theaitetos - You beat me the punch - I just sat down to write up the fix after playing with debug=5 earlier today and realized the parser function #titleparts was being processed before being returned with the format, thus I needed to use ²{ }² to parse it after the fact because it was parsing #titleparts before %TITLE% was being returned. This of course led to knowing I needed the broken pipe ¦ instead of | and I had it working with your first example.
I didn't use the replaceintitle= because I am need two things to pass, the parent title and the child title which are completely different. Using replaceintitle is a great idea, but the it sets %TITLE% to the value of the parent title, which is the displayed link title and trying to call it a second time when I really need the child page name as a parameter it fails because %TITLE% will now return as only the parent name.
I will change the {{NAMESPACE}} to use {{NAMESPACEE}}, I didn't think of anyone using it in a NAMESPACE like the _talk NAMESPACE. I don't think there are any NAMESPACEs on the wiki it is being used on with the break in NAMESPACE names, but it is a good idea to plan ahead. This is all Great stuff! Thanks again! -- Hutchy68 (talk) 20:37, 16 September 2012 (UTC)Reply[reply]

After DPL pages have another category edit

I've installed DPL in a MW 1.19.2 and I used only simple codes, for example




I noted that:

  1. With these codes I list also some categories.
  2. Since a category is classified for example as "CL", then also the page with the code is classified as "CL".

How can I avoid these two issue?

Thanks in advance --WhiteTigerItaly 07:02, 10 October 2012 (UTC)Reply[reply]

You will have to use the reset parameter. That should do it, but if it doesn't, take a look at eliminate and fixcategory. --Theaitetos (talk) 01:31, 11 October 2012 (UTC)Reply[reply]

Behavior with $wgNonincludableNamespaces edit


thanks for the extension! Would it be possible to make it configurable whether the variable $wgNonincludableNamespaces is recognized? I have a use case where I need to set $wgNonincludableNamespaces for transclusion but need to allow DPL to show pages titles from all namespaces and prevent DPL inlcusion via function richness settings in DPLsetup.php. (MW1.19, DPL 2.1)

Thanks or support! --Filburt (talk) 12:37, 11 October 2012 (UTC)Reply[reply]

Does the richness functionality in DPLsetup.php work? edit

Hi again,

I changed the $validParametersForRichnessLevel in DPLsetup.php - i.e. I moved the include - functionality from level 2 to 3 - but nothing changed. Do I have to make some more changes? (MW1.19, DPL 2.1)

Thanks a lot! --Filburt (talk) 12:47, 11 October 2012 (UTC)Reply[reply]

Sort by custom date field? edit

This extension has been a real leap forward for the intranet wiki I'm running even though I'm only using it for the simplest of purposes, i.e displaying a feed of links to newly added content within various categories or intersections. Right now the lists are sorted using addfirstcategorydate, which is fine up to a point. But since we're adding documents and data that are sometimes older than what's already there (we're effectively building an archive) the result is sometimes confusing for users. As far as I can see the other date-sorting options (lastedit etc.) would not help. So I'm wondering if there is a relatively simple way of creating a custom date field on the page to mark content with its date of provenance and then having DPL sort by that. The capabilities of this extension appear to be amazing, but I'm afraid the advanced stuff finds me quickly out of my depth. So I'd be much obliged for any pointers anyone might have, or even to know whether I'm barking up the wrong extension here. Themicksa (talk) 13:21, 7 November 2012 (UTC)Reply[reply]

DPL can retrieve information, that you put into templates, even if those templates don't show anything. For example, if you want to mark those pages with a date, by which the pages should be sorted, then just add somewhere on that page the template date (e.g. {{timestamp|2012/11/07}}), then create the page Template:Timestamp as empty page or something. Now the DPL call can retrieve that by the command
  include = {timestamp}:1
Depending on how your DPL call is structured you can then sort by this value; for example, if you use a table, just add the column "Date" to the table, where the retrieved timestamp shows up and then sort by this table column tablesortcol = 5, if "Date" is the fifth column. --Theaitetos (talk) 18:16, 7 November 2012 (UTC)Reply[reply]
Wow. Thanks for the quick reply. Even better I think I understand that solution and look forward to trying it out. Themicksa (talk) 20:42, 7 November 2012 (UTC)Reply[reply]
OK. Progress of a kind. The timestamp template solution works and although the content isn't normally within a table (and doesn't otherwise need to be) I have got close to what I need using the following code:
 |category= Good News
 |category= UK Grants
 |category= International Grants
 |notcategory= Global
 |notnamespace= Category
 |include = {timestamp}:1
 |tablesortcol = -2

This gives me a list of page titles followed by the timestamp date that are sorted with latest at top--all great. I've used an existing table class and can create a more suitable one if needs be, but I'm wondering if there is a way of doing it without the table (i.e. is tablesortcol the only way of sorting the timestamps.

Also, I'd like to use different date format; is that governed by the format in the timestamp template or can it be set via the DPL? (I'm presuming that the ordermethod= option is redundant here.)

Finally i'd like to include a bullet at the front of the line. I tried playing around with the example in the Manual

|format   = ,\n* [[%PAGE%|%TITLE%]],,

but it doesn't work when used along with the table= parameter and I'm not sure how or where to place {timestamp} in that. In short, can I also use format= to give me this: • Pagename dd/mm/yyy

Thanks again for your help Theaitetos and even more thanks if you can shed any more light in my dimness.

Themicksa (talk) 14:07, 8 November 2012 (UTC)Reply[reply]

Using the bulletpoint-syntax inside a table is already a little bit tricky in Mediawiki itself, as |* would just give you a line starting with a mere *. Although an additional newline would do the job, it isn't really necessary, as we can simply put the bulletpoint wherever we need it manually.
As for "format": When you use the format= parameter, every other formatting is suppressed, so you have to write down everything you want as output using the given variables; i.e. you can't use table= along with it, but you can write down a table in the format= parameter:
 |format = {¦ , \n¦- \n¦ • ¦¦ [[%PAGE%]] ¦¦ , , \n¦}
and then you should be able to use tablesortcol = 3 to get the job done, as the included content will simply appear at the position of the 2nd comma. If you want the Mediawiki bulletpoint, you would have to replace the with \n*. Sorting output outside of tables is atm only possible with the DPL intrinsic parameters and none of them helps you in this case, so you will have to use a table. But since tables are highly customizable, that shouldn't be a big layout problem, just add the desired css-style right after the "{|" table beginning.
The content of the template:timestamp is irrelevant to the output, but what you enter in the respective pages is what is important as that is the included content, so when you write down {{timestamp|2012-11-09}} on Olympics 2012 then Olympics 2012 2012-11-09 is exactly what appears. And when you write {{timestamp|"2012-11-09"}} then you get Olympics 2012 "2012-11-09". DPL isn't doing anything with the transcluded content here, it just repeats what is written on the respective page. So you would have to change those pages in the way you want it to appear. -Theaitetos (talk) 16:41, 9 November 2012 (UTC)Reply[reply]
Thanks once again for the help which I'm only just now finding the time to implement. Unfortunately, I'm now floundering. I can get the display I require by using the following:
include = {timestamp}:1
tablesortcol = -2
count   = 10
format = {¦ , \n¦- \n¦ \n*  [[%PAGE%]] {{Align|Right|,}}, \n¦}
I got that through trial and error so I'm not sure I understand everything. This gives me a bullet followed by the pagename, followed by the timestamp date as entered on each page (aligned to the right). However, the items are not ordered by the date stamp. Is the tablesortcol ref wrong? Or perhaps the timestamp template is at fault:
Template is: —Post date: {{{1}}}
ON the page is: {{Timestamp|2012/11/29}}
btw The timestamp sort was working in my earlier attempt, but ideally I would like that to be sorted AND displayed in a different format, ie dd/mm/yyyy. Can that be handled within the DPL code or is it a function of the timestamp.
I realise that I'm well out of my depth here, but I'd be so grateful for a hand in getting over this hump, so I can get back to churning out pages. thx and best. Themicksa (talk) 15:56, 29 November 2012 (UTC)Reply[reply]
Quick question: Can you link me to your wiki, so I can have a real look at it and possibly edit things to get it done? It's easier to explain then. Otherwise here's an idea:
Create a new (sub-)template Template:Timestamp/dpl and enter the following code (requires string functions enabled):
<span style="display:none;">{{{1}}}</span> {{#sub:{{{1}}}|8|2}}-{{#sub:{{{1}}}|5|2}}-{{#sub:{{{1}}}|0|4}}
You should then be able to just write include = {timestamp}/dpl and revert to the old table-statement along with tablesortcol = 2 to have it sorted and displayed the way you want. Basically the "invisible span" makes sure that the timestamp is written there (for sorting) but invisible to the eye; while "sub" helps retrive the different parts of the 1st parameteter to make sure that it first displays day, then month, then year. --Theaitetos (talk) 18:34, 30 November 2012 (UTC)Reply[reply]
I'm immensely grateful for all your help with this, but I have to conclude there is just too much here I don't understand and unfortunately, because this is behind our firewall, there's no way to give you a link to get in and take a look. I'd be happy to send or link you to copies of the relevant pages, but I think that might be making life a bit too complicated all round. Right now the following code or variations :
 |category= Good News¦Impact¦UK Grants¦International Grants
 |notcategory= Global
 |notnamespace= Category
 |include = {timestamp}:1
 |tablesortcol = -2
 |count   = 100
 |format   = , [[%PAGE%|%TITLE%]],,
is giving me a functional list of the correct pages followed by and sorted by date. That's way better than when I started out, so I'll settle for that and save the formatting niceties for another day. Again, many thanks for your help. It really is much appreciated. Themicksa (talk) 11:45, 3 December 2012 (UTC)Reply[reply]

Passing parameters from DPL to Semantic MediaWiki edit

I'm trying to created a template that will output a dynamic report by generating a list of pages with Dynamic Page List and then run queries on each page using Semantic Mediawiki, outputting the whole mess in a table. The structure of the template looks like this:

{| class="wikitable sortable collapsible collapsed" width="100%"
|- valign="bottom"
! width="15%" | Compound ID
! width="15%" | Generic name
! width="15%" | Trade name
! width="15%" | Developer
! width="10%" | Phase of development
! width="30%" | Target

 | category=compounds
 | linksto={{PAGENAME}}{{#dpl: linksto={{PAGENAME}} | redirects=only | mode=userformat | format=,{{!}},%TITLE%, | suppresserrors=true }}
 | ignorecase=true
 | distinct=strict
 | format=,{{!}}- valign="top"\n{{indication-based compound list/row|%TITLE%}}\n
 | noresultsheader={{!}}-\n{{!}} colspan="6" align="center" {{!}} ''No compounds have yet been studied for this indication.''


The row formatting template, {{indication-based compound list/row}}, consists of the following:

<includeonly>{{!}} {{#show: {{{1}}} | ?compound id }}
{{!}}{{!}} {{#show: {{{1}}} | ?compound generic name }}
{{!}}{{!}} {{#show: {{{1}}} | ?compound trade name }}
{{!}}{{!}} {{#show: {{{1}}} | ?developer }}
{{!}}{{!}} {{#ask: [[category:clinical studies]][[compound number::{{{1|}}}]]
 | ?study phase=
 | limit=1
 | mainlabel=-
 | searchlabel=
 | sort=study phase
 | order=descending
{{!}}{{!}} {{#show: {{{1|}}} | ?target }}</includeonly>

The {{#ask}} query is the reason why this isn't just a straight-forward DPL table: because the current phase of clinical development of a specific compound for a specific indication is a dynamic piece of data that changes frequently, the only option seems to be using an {{#ask}} query to find out the highest value for study phase among the clinical trials that meet the parameters. But this template will be surveying auto-generated pages and I don't have a way of auto-loading a list of indications for each compound (to apply semantic markup to), so instead it's generating based on lists of indication links that are themselves generated by a {{#dpl}} function on each compound page.

I've walked through this step by step, and none of the following are the problem:

  1. The template code is sound, and generates the proper structure.
  2. The table row template is sound, and if I remove the {{#dpl}} function and replace it with the template and a compound page name as a parameter, e.g. {{indication-based compound list/row|infliximab}}, it creates exactly the output I'm looking for.
  3. The {{#dpl}} function produces the correct list of pages when using the default output format.
  4. The {{#dpl}} function passes the list as sequential parameters properly when using format = ,{{[[Template:{{{1}}}|{{{1}}}]]}} with a simply dummy template (just an unordered list).

However, when I put all the pieces together I just get empty table cells. The {{#show}} and {{#ask}} functions can't seem to accept the DPL input as parameters. Is there an additional argument or intermediate step I'm skipping that can sanitize the input and make the whole thing work? Or are DPL and SMW fundamentally incompatible in this way?

  • DynamicPageList 2.01
  • Semantic MediaWiki 1.8
  • MediaWiki 1.20.2
  • PHP 5.3.19 (apache2handler)
  • MySQL 5.1.30


I am not too familiar with the SMW extension, but this isn't the first time, that suggests incompatibility issues between the two extensions, i.e. each of them works fine on its own, but they fail when put together. Having them work together fine requires changing the very code of the two extensions, which at this moment is very unlikely to happen. Yet, I might have an idea as to how you can achieve what you want: You will need to install the Extension:Variables and instead of calling upon the template {{indication-based compound list/row|%TITLE%}} directly, you can use the primary DPL call to define variables, which you can then use to call the template after the DPL call itself. So place the dpl call above your table and change it as follows:
  |format = , ²{#vardefine:%NR%¦%PAGE%}² ,,
  |resultsheader = ²{#vardefine:TOTAL¦%PAGES%}²
This DPL call will produce no visible output, but now the variable {{#var:TOTAL}} gives you the total amount of pages that were found by the DPL call and the variables {{#var:1}}, {{#var:2}}, {{#var:3}}, ... will give you said pages. You should then be able to use the template {{indication-based compound list/row|{{#var:1}}}} and so forth to produce your table output without another DPL call (which might erase your variables). It's not the most straightforward way, but the only one that comes to my mind atm. Good luck! --Theaitetos (talk) 12:55, 23 February 2013 (UTC)Reply[reply]

Tablerow parameter including too many columns edit

In my wiki (concerning beekeeping in the game Minecraft), I want to build on an overview page a list of all bees, which have a certain temperature tolerance. Each bee uses several templates on its page. The relevant ones here are Bee and Attributes. The Bee template gives me the information I want displayed via the tablerow parameter, the Attributes template gives me the parameter, on which includematch selects the bees.

Code I tried:

  |category     = Bees
  |includematch = ,/temp-tol\s*=\s*\-2\s*\R/i
  |include      = {Bee}:name, {Attributes}:temp-tol
  |table        = class="wikitable",-,Down 2
  |tablerow     = [[File:Bee-%%.png|32px]] [[%% Bee]]

Result: Selection works, but the table has two columns. The first one has the picture and textual link to the article as I want, the second one (unwanted) gives me the content of the temp-tol variable. According to the DPL-Manual: "Skipping a column would suppress output for that column completely.", but I don't define a second column (neither in table, nor in tablerow), so I expected to get a single column table.

I can workaround this by using a surrogate template for Attributes, which only contains a &nbsp;, but is it possible without this? At what point lies my thinking error? -- 20:07, 22 February 2013 (UTC)Reply[reply]

I think the manual is out of date on this one. To make things easier for new users, the default has changed to always add colums, when there is more content included via the "include=" statement. In order to not have it, you need to manually suppress the visible output. I recommend changing the last line to:
  |tablerow     = [[File:Bee-%%.png|32px]] [[%% Bee]] <span style="display:none;">«nowiki»,«/nowiki»</span>
If you want to, you could even put the temp-tol output invisible in front of the image and use it for sorting purposes. Tell me if it doesn't work out and I have another look at it. --Theaitetos (talk) 12:33, 23 February 2013 (UTC)Reply[reply]
Thank you very much, it worked perfectly. -- 23:33, 24 February 2013 (UTC)Reply[reply]

Tablerow parameter - Use of default values possible? edit

First the code:

  |category     = Bees
  |includematch = /prod-s\s*=/i, /(humid{{!}}temp)\s*=/i
  |include      = {Bee}:name, {Attributes}:temp:humid
  |table        = class="wikitable sortable",-,Bee,Temp,Humid
  |tablerow     = [[File:Bee-%%.png|32px]] [[%% Bee]],%%,%%

The template parameters for the Attribute template (temp and humid) can sometimes be empty. Is it possible to display an alternative text for these cases in the tablerow parameter?

Code I tried:

  |tablerow     = [[File:Bee-%%.png|32px]] [[%% Bee]],{{#if: %% {{!}} %% {{!}} Normal}},{{#if: %% {{!}} %% {{!}} Normal}}
  • Line of reasoning: IF %% is non-empty THEN display %% ELSE display 'Normal'.
  • Result: Empty cells everywhere in column 2+3, independent of the usage of the temp or humid parameter.
    • I've found the error myself. The code which works is:
  |tablerow     = [[File:Bee-%%.png|32px]] [[%% Bee]],²{#if: %% {{!}} %% {{!}} Normal}²,²{#if: %% {{!}} %% {{!}} Normal}² 13:27, 14 March 2013 (UTC)Reply[reply]

Exactly, you need to employ escape characters here. The other escape characters are:
escape character corresponding wiki character
« <
» >
²{ {{
\n newline
¦ |
{{!}} |
{{!!}} ||
The templates {{!}} and {{!!}} can, obviously, only be used, if you define them first in your wiki. --Theaitetos (talk) 14:49, 15 March 2013 (UTC)Reply[reply]

DPL ignores words with +1 or (R) in the Name edit

Hey Guys, Hey Theaitetos :)

i use the Version 2.01 and the following code down.

|category=Kategorie:{{{Name|}}} Monster
|notcategory=Kategorie:Berüchtigte Monster
|namespace     = 
|includepage = {Monsterzeile} dpl 4
|includematch = /\s*Ort\s*{{=}}\s*{{{Name|}}}/si
|format      =,,\n
|tablesortcol= 1
|table       =class="SE-Heaventable sortable" style="width: 100%;",Name,Pos,Level,Hinterlässt,Familie
|tablerow =%%,%%,%%

If {{{Name|}}} is like XYZ +1 or ZYX (R) it dosen't works. I got only this message in German: Extension:DynamicPageList (DPL), version 2.01 : Warnung: Kein passender Eintrag gefunden! Any Idea how i can fix it? Yukii (talk) 18:34, 31 March 2013 (UTC)Reply[reply]

Hallo. Das Problem dürfte hier in der Zeile |includematch = /\s*Ort\s*{{=}}\s*{{{Name|}}}/si stecken, denn Zeichen wie (, ) oder + sind RegEx-Metazeichen. Wenn also ein solches Metazeichen in {{{Name|}}} vorkommt, funktioniert es nicht. Du musst die Metazeichen also erst per \ entwerten, sodass sie als normale Zeichen aufgefasst werden. Das kannst du bspw. durch {{#replace:{{{Name|}}}|+|\+}} für das + erreichen. --Theaitetos (talk) 19:48, 31 March 2013 (UTC)Reply[reply]
Hallo Theaitetos, danke schon mal für deine Antwort. Das mit dem {{#replace:{{{Name|}}}|+|\+}} hat schon mal sehr gut funktioniert, danke. Das mit den Klammern krieg ich irgendwie noch nicht gebacken. Wenn ich das richtig sehe, kann ich mit Replace doch nur ein Zeichen ersetzen oder gibt es da vielleicht einen trick? Yukii (talk) 07:16, 1 April 2013 (UTC)Reply[reply]
Hallo (und frohe Ostern). Einen Trick gibt es nicht, aber du kannst es einfach mehrfach anwenden: {{#replace:{{#replace:{{#replace:{{{Name|}}}|+|\+}}|(|\(}}|)|\)}}.
Übrigens, in den Zeilen für Kategorieangaben kann man das Kategorie: weglassen, also statt category=Kategorie:{{{Name|}}} Monster oder notcategory=Kategorie:Berüchtigte Monster einfacher category={{{Name|}}} Monster bzw. notcategory=Berüchtigte Monster.
Eine weitere Kleinigkeit: Bei RegEx-Ausdrücken wie includematch = /\s*Ort\s*{{=}}\s*{{{Name|}}}/si sollte man das = eigentlich ohne Vorlage verwenden können. Und zur Übersichtlichkeit verwende ich als Anfangs- und Endzeichen immer ein @, da dass ja praktisch nie vorkommt in Parameterwerten, es würde also so aussehen: includematch = @\¦\s*Ort\s*=\s*@si (das ¦ ist das Ausweichzeichen für | in DPL; man kann alternativ aber auch {{!}} verwenden).
--Theaitetos (talk) 13:48, 1 April 2013 (UTC)Reply[reply]
Hallo und dir natürlich auch Frohe Ostern :). Also das "verschachteln" hab ich jetzt mal versucht, aber es bringt nicht den gewünschten Erfolg. Bekomme leider immer noch die Meldung Extension:DynamicPageList (DPL), version 2.01 : Warnung: Kein passender Eintrag gefunden! :\
Das mit der "Kategorie:" weglassen ist mir schon bekannt. Die Vorlagen hatte ich noch zur Zeit des alten DPLs gemacht und da hatte ich ohne dieser angabe paar probleme gehabt, daher ist das noch Gewohnheit ;)
Das werde ich mir mal ansehen. Klingt gar nicht mal so verkehrt,
Yukii (talk) 18:18, 1 April 2013 (UTC)Reply[reply]
Ich verbessere mich, die verschachtelte Variante klappt nun. Das hat sich wohl mit ner anderen Vorlage irgendwie gekappelt. Ich danke dir Theaitetos für die hilfe :) Yukii (talk) 18:57, 1 April 2013 (UTC)Reply[reply]

Renaming this extension on Special:Version to have (tp) in brackets edit

Kghbln has proposed over at gerrit:43868 to have the name of this extension on Special:version be changed to DynamicPageList (tp). Does anyone have any objections? Would DynamicPageList (third-party) be better? If no one has any objections in the next little while (say a week or so) I intend to merge the change. (I feel a little weird merging changes like this, since I am not a maintainer of this extension, but no one else is commenting/merging changes to this extension). Thanks Bawolff (talk) 01:23, 4 April 2013 (UTC)Reply[reply]

Thanks for the notification. Somehow the mail ended up in the spam folder of a secondary mail address. IIrc Algorithmix intended renaming it to "Dynamic Page List 2", though I guess that might be a bit confusing as well, which is why I prefer "third-party" to "tp". --Theaitetos (talk) 17:33, 4 April 2013 (UTC)Reply[reply]
I am perfectly fine with the suffix ("third party") or ("tp"). Algorithmix (talk) 06:43, 1 May 2013 (UTC)Reply[reply]

2013 edit

DPL (2.0.1) & Cite throw notice edit

The Usage of DPL and Cite throws the following notice on my Mediawiki 1.20.5: Notice: Undefined property: Cite::$mInCnt in /extensions/DynamicPageList/DPL.php on line 78

on http://en.wiki-products.org/

Any ideas, what to look for? Thanks in Advance, --Francishunger (talk) 13:01, 6 May 2013 (UTC)Reply[reply]

Could you provide me with an account to your wiki, so I can take a look? --Theaitetos (talk) 17:51, 6 May 2013 (UTC)Reply[reply]
please contact me at info at design-hunger dot com --Francishunger (talk) 11:57, 8 May 2013 (UTC)Reply[reply]

I just checked and the Cite extension bundled with 1.19 makes use of $mInCnt. Versions bundled in 1.20 and later no longer contain the variable. For my personal fix, I just commented out line 78 and 89 of DPL.php. Fereal (talk) 11:36, 26 May 2013 (UTC)Reply[reply]

I just did an upgrade from MediaWiki 1.20.6 to 1.21.1 on www.mobadaten.info. With 1.20.x, particularly with 1.20.5 too, it worked fine. With 1.21.1 the above error message turned up. I just also commented out line 78 and 89 of DPL.php. --Wgkderdicke (talk) 08:08, 3 August 2013 (UTC)Reply[reply]

Hi All Version 1.21 here similar errors + a bonus to do with skins? - commented out all lines unsure on impacts - default skin set to monobook -I'm running this locally on an XAMPP install as a test bed before implementation of extensions/templates on server.

Strict Standards: Only variables should be assigned by reference in F:\xampp\htdocs\wiki\extensions\DynamicPageList\DPLMain.php on line 2549

Notice: Undefined property: Cite::$mInCnt in F:\xampp\htdocs\wiki\extensions\DynamicPageList\DPL.php on line 78 (once commented out line 89 reported as well as above)

Strict Standards: Only variables should be assigned by reference in F:\xampp\htdocs\wiki\extensions\DynamicPageList\DPL.php on line 284

Updating to 1.21 edit

I was attempting to update my wiki to 1.21rc5 and got the following error when trying to run update.php:

A database error has occurred. Did you forget to run maintenance/update.php after upgrading?  See: https://www.mediawiki.org/wiki/Manual:Upgrading#Run_the_update_script
Query: SELECT  page_id,page_len,page_is_redirect,page_latest,page_content_model  FROM `page`  WHERE page_namespace = '10' AND page_title = 'Extension_DPL'  LIMIT 1
Function: LinkCache::addLinkObj
Error: 1054 Unknown column 'page_content_model' in 'field list' (localhost)

I was able to get around the problem by disabling DPL, doing the update, and then re-enabling DPL. -- Prod (talk) 00:21, 18 May 2013 (UTC)Reply[reply]

Hello, try this: ALTER TABLE /*$wgDBprefix*/page ADD page_content_model varbinary(32) DEFAULT NULL; --Krusher (talk) 13:42, 19 June 2013 (UTC)Reply[reply]
Disabling DPL didn't work on my wiki (wonder why), while using phpMyAdmin to add a "page_content_model" field to the "page" table, varbinary(32) and no default, solved the problem. -- 09:58, 29 June 2013 (UTC)Reply[reply]

trouble with includematch edit

Software Version
MediaWiki 1.20.2
PHP 5.3.3-7+squeeze15 (apache2handler)
MySQL 5.1.66-0+squeeze1
DynamicPageList (Version 2.01)

I need to read a special pattern like "Drops" from a Template its called "Row"

|Name = 
|Drops = Item1, Item2, Item3, Item4
|Pattern3 = 
|Pattern4 =  

my DPL code looks like so:

| category= Item1 drops from XY
| includepage = {row} dpl 2
| namespace     = 
| format      =,,\n
| table       =class="SE-Heaventable sortable" border="1" style="width: 100%;",Name,Level,Ort,class="unsortable"{{!}}Besonderheiten,class="unsortable"{{!}}Hinweis,class="unsortable"{{! }}Typ
| tablerow =%%,%%
| suppresserrors=true

row dpl 2 looks like so:

{{!}}{{#if: {{{Ort|}}}|[[{{{Ort|}}}]]|}}

{{!}}{{#if: {{{Ort-Hinweis|}}}|<br><small>{{{Ort-Hinweis|}}}</small>|}}

{{!}}{{#switch: {{{Stehlen|}}}|{{PAGENAME}}|{{{Name|??}}} =[[Datei:Stehlenicon.png|25px|Gegner wird Bestohlen]]|= }}{{#switch: {{{Ausrauben|}}}|{{PAGENAME}}|{{{Name|??}}} =[[Datei:Ausraubenicon.png|25px|Gegner wird Ausgeraubt]]|= }}{{#switch: {{{Fleddern|}}}|{{PAGENAME}}|{{{Name|??}}} =[[Datei:Fleddernicon.png|25px|Gegner wird Gefleddert]]|= }}

{{!}}{{#switch: {{{Typ|}}}|NM|Notorisch|nm|Berüchtigtes Monster='''[[:Kategorie:Berüchtigte Monster|NM]]'''|Auftrag|Quest|Mission|AM|QM|MM ='''[[:Kategorie:Auftragsmonster|AM]]'''|Event|EM ='''[[:Kategorie:Eventmonster|EM]]'''|}}
<noinclude>[[Kategorie:Vorlagen (DPL)|{{{PAGENAME}}}]][[Kategorie:Vorlagen (Geschützt)|{{{PAGENAME}}}]]</noinclude>

Now the DPL works in the Moment so, he Read and listen all "Rows" where the first Item is Item1 and all other Rows. Now i looked in the Manual

If the parameter is not the last one in your template call you might use

and i have to do a includmatch where he reads out the complete line "Drops". If "Item1" should be the third, or last entry he has to read it. But, i reads only the Rows, where Item1 is the FIRST entry by "Drops =" you can see down the new Code:

|dplcache= 1-drops{{PAGENAME}}drops-1
| category= Item1 drops from XY
| includepage = {row} dpl 2
| namespace     = 
| format      =,,\n
| includematch =  /\s*row\s*{{=}}\s*item1/si
| table       =class="SE-Heaventable sortable" border="1" style="width: 50%;",Name,Lvl,Ort,class="unsortable"{{!}}Hinweis,class="unsortable"{{! }}Typ
| tablerow =%%,%%
| suppresserrors=true

If i try it with the includmatch example from the Manual like this:

|dplcache= 1Pop6456456345test02wer
| category= Item1 drops from XY
| includepage = {row} dpl 2
| namespace     = 
| format      =,,\n
| includematch=/\{{!}}\s*item1\s*\|/s
| table       =class="SE-Heaventable sortable" border="1" style="width: 50%;",Name,Lvl,Ort,class="unsortable"{{!}}Hinweis,class="unsortable"{{! }}Typ
| tablerow =%%,%%
| suppresserrors=true

i got this following error:

Extension:DynamicPageList (DPL), version 2.01 : Warnung: Der unbekannte Parameter '/s [missing '=']' wird ignoriert. Hilfe: Verfügbare Parameter: addfirstcategorydate category count hiddencategories mode namespace notcategory order ordermethod qualitypages redirects showcurid shownamespace stablepages suppresserrors allowcachedresults execandexit columns debug distinct escapelinks format inlinetext listseparators notnamespace offset oneresultfooter oneresultheader ordercollation noresultsfooter noresultsheader randomcount randomseed	 replaceintitle resultsfooter resultsheader rowcolformat rows rowsize scroll title title< title> titlemaxlength userdateformat addauthor addcategories addcontribution addeditdate addexternallink addlasteditor addpagecounter addpagesize addpagetoucheddate adduser categoriesminmax createdby dominantsection dplcache dplcacheperiod eliminate fixcategory headingcount headingmode hitemattr hlistattr ignorecase imagecontainer imageused include includematch includematchparsed includemaxlength includenotmatch includenotmatchparsed includepage includesubpages includetrim itemattr lastmodifiedby linksfrom linksto linkstoexternal listattr minoredits modifiedby multisecseparators notcreatedby notlastmodifiedby notlinksfrom notlinksto notmodifiedby notuses reset secseparators skipthispage table tablerow tablesortcol titlematch usedby uses allrevisionsbefore allrevisionssince articlecategory categorymatch categoryregexp firstrevisionsince lastrevisionbefore maxrevisions minrevisions notcategorymatch notcategoryregexp nottitlematch nottitleregexp openreferences titleregexp deleterules goal updaterules .

So what do i wrong? Yukii (talk) 08:59, 28 June 2013 (UTC)Reply