Difference between revisions of "DPL:FAQ"

From FollowTheScore
Jump to: navigation, search
(includematch: new section)
Line 556: Line 556:
  
 
Hi! I want to select pages which contains 'hello world' in Example chapter. As i understand 'includematch' can help me, but i don't understand how to make it... I tried to paste expression from examples and always got PHP errors (about delimiter or offset). I just want to select pages which contains 'hello world' to add them to the table. What do i need? --[[User:Maaboo|Maaboo]] 13:37, 24 April 2009 (UTC)
 
Hi! I want to select pages which contains 'hello world' in Example chapter. As i understand 'includematch' can help me, but i don't understand how to make it... I tried to paste expression from examples and always got PHP errors (about delimiter or offset). I just want to select pages which contains 'hello world' to add them to the table. What do i need? --[[User:Maaboo|Maaboo]] 13:37, 24 April 2009 (UTC)
 +
 +
== Used and unused images ==
 +
Is there a way to select images that are used (il_to NOT NULL, linked to by any other page)) or unsed? --[[User:Subfader|Subfader]] 00:50, 29 April 2009 (UTC)
 +
 +
== Selection by MIME types? ==
 +
Is it possible to select file page titles by img_major_mime or img_minor_mime? E.g. a list of images (img_major_mime=image) or a list of PDF files (img_minor_mime=pdf). --[[User:Subfader|Subfader]] 00:50, 29 April 2009 (UTC)
 +
 +
== Last edits which are not page creations? ==
 +
How to list pages which were recently edited by a specified user but excluding those which were created by that user but not edited afterwards? I'm using this atm:
 +
<pre>|modifiedby=UserName
 +
|ordermethod=lastedit
 +
|order=descending</pre>
 +
So: Do not don't count page creation as edit. Any ideas? --[[User:Subfader|Subfader]] 00:50, 29 April 2009 (UTC)

Revision as of 01:50, 29 April 2009

Contents

I want to create a "Category Cloud." How do I change the font size based on the number of articles for a category?

You have to use one dpl query to select a list of suitable categories. Within the format statement of that query you call another query (in a separate template) which calculates the number of members for each category. This template uses #expr to calculate the font-size. Make sure to use an advanced version of ParserFunctions extension which really understands "floor" and "sqrt".

For an example see Test category cloud.

Thank you! I really appreciate your help. Your programming is awesome. (BTW, following your advice, I needed the extended parser functions). This is a great way of quickly "seeing" a large number of articles. -Jim Miller

My article name contains underscores, but in the DPL result they won´t appear.

Normally, DPL replaces all undercores in article names by spaces when showing the result. You can replace underscores by their symbolic html name via the 'replaceintitle' statement. So DPL will no longer recognize the underscores and later the html engine will translate the symbolic name to underscores.

This wiki contains an Article_with_underscore. Normally DPL would show it as . But with {{#dpl:titlematch=%underscore|replaceintitle=/ /,&#95;}} you will get

When I use multi-column output my background color is cluttered

There is a special parameter named rowcolformat which allows to set the background color, cell-spacing etc. in combinaton with 'columns=' or 'rows='. See also DPL:Requests_for_new_features_Archive#Global background-color.

When I write a "What links here" DPL query, redirections are ignored

Say you have an Article A1 which links to B and an Article A2 which links to B2. But B2 is redirected to B.

{{#Wgraph: name=FAQ1 | png | thumb=50 |

 node A1 {color=green}
 node A2 {color=green}
 node B  {color=red}
 node B2 {color yellow}
 edge A1 B {}
 edge A2 B2 {}
 edge B2 B {label = #REDIRECT }
 orientation = left_to_right

}}

A standard DPL query using

linksto = B

will only deliver Article A1 because the default is to ignore #redirects.

redirects = include
linksto = B

will give you Article A1 and B2 as B2 redirects to B. But this may not be what you want. You still won´t get A2 as it links to B2 and not to B. The trick is to get the direct links to B in the normal way and to use a nested subquery which finds the pages which link to pages that redirect to B. We write the query in a way that it accepts the name of the target page (B) as a parameter:

Template:LinksToWithRedirect
----------------------------
 {{#dpl:
  |linksto={{{1}}}
 }}
 {{#dpl:
  |linksto={{{1}}}
  |redirects=only
  |format=,²{LinksTo¦%PAGE%}²,
 }}

Template:LinksTo
----------------
 {{#dpl:
   |debug=1
   |linksto={{{1}}}
   |format=,*[[%PAGE%¦%TITLE%]]\n,
 }}

Now calling {{LinksToWithRedirect|B}} will return A1 and A2.


See also Listing Redirects and Location

Getting pages with references to templates with particular parameters

With DPL you can find all pages which use a certain template. You can specify that you only want to see those articles where a ceratin parameter of that template has a certain value. You can even allow for a group of values if you use the power of regular expression as the following examples shows:

Let's say that your company uses a wiki to assign and keep track of tasks. So, let's say that you have created a todo template which, as a parameter, takes the name, username, or some other semblance of a name of a person responsible for the task. If you now want to see the tasks which have been assigned to a given person you could use something like

<dpl>
    uses        = Template:Todo2
    include     = {Todo2}:1,{Todo2}:2
    includematch= /\|(Sam Brown)|(Brown)|(SBrown)/i
    table       = ,,Person,Task
</dpl>

which produces

Content page Person Task
Todotest1 Brown, Sam To be done by Brown, Sam
Todotest2 Sam Brown To be done by Sam Brown
Todotest3 SBrown have to do what it says by SBrown

Note that the "i" makes the regexp case insensitive, so 'sbrown' would also match.

How do I produce a list or a table that begins with a template parameter instead of the article name?

Whenever I create a dpl list or table with template parameters it always produces a list with the article name appearing first. I would like one of the template parameters to appear first instead. For example, all the titles of books are the article names and each has a template with author, publisher, place of publication, and date. I would like to create a list in the format author, article title, place of publication, publisher, date (i.e., I want to automatically create bibliographic references in Chicago style with DPL). Is there a way to do this? Marcusperman 04:22, 7 March 2009 (UTC)

Yes, there is a way: use a "-" as the second parameter of the table statement and use a phantom template which produces table rows. In this phantom template you can put a [[{{{%PAGE%}}}]] parameter in whatever column you like. Gero 17:52, 7 March 2009 (UTC)

Inserting spaces and comma in the output

Just use the numeric html alias for comma: &#44;; you may want to have a space after that 'comma', so line wrapping will work normally:

{{#dpl:category=MyItems|listseparators=,[[%PAGE%|%TITLE%]]&#44; ,,}}

I want the article list separated by comma

There is a mode called 'inline' which does what you want.

mode=inline
inlinetext=,&nbsp;

This will give something like Nig1Nig2Nig3Nig4

Why does my deleted page still appear on Special:Wantedpages?

When a page is categorized such that it appears in a DPL query and is subsequently deleted, it will immediately disappear from the DPL query results. However, depending on how long the page has been around, it will temporarily still appear on Special:Wantedpages and navigating to the page's What Links Here page will still show the DPL query page as a page that links to it.

To get it to stop that unruly behavior, do one of the following:

  • Wait awhile (an hour or so). The wiki will sort this out over time in a background process.
  • Execute 'php runJobs.php' in the maintenance folder of your MediaWiki installation
  • Open the DPL query page in edit mode and save it again (this will add to your Recent Changes page)
  • Add reset=all in a final DPL query on the query page (see here.) This has other side effects - read about it first.

Why does my deleted page still have a link to a query page in its What Links Here list?

The answer to this is already in the previous section, but we wanted you to be able to find your question anyway.

How do I 'see' the wikitext my DPL generates?

There is a simple trick to DEBUG your DPL script:

Use a resultsheader and a resultsfooter to enclose all DPL output in pre and nowiki tags like this:

<dpl>
  ...
  resultsheader=<pre><nowiki>
  resultsfooter=</nowiki></pre>
  ...
</dpl>

NOTE: since version 1.4.2 you can also use the debug parameter. Just set "debug=5" in your DPL!

How do I offset an ordered list by a certain number?

Use the format statement and define an offset for the list:

<dpl>
  category=Fictitious country
  format=<ol start="4">,<li>%PAGE%</li>,\n,</ol>
</dpl>
  1. DPL Example 007 main page 1
  2. Nigunda
  3. Nigunda Test
  4. Somango

Can DPL improve the MediaWiki search dialogue?

You can use DPL to show a list of files which match the search expression.

You could change your Mediawiki:Noexactmatch template as follows:

  '''There is no page titled "$1".''' You can [[:$1|create this page]].
  <dpl>
    debug=1
    resultsheader=    ''There are some pages similar to '$1':''\n
    titlematch=%$1%
    ignorecase=yes
  </dpl>

As an example enter 'rep' into the searchbox of this wiki and watch the response page.

How do I create tabular output?

The answer is (surprisingly) quite simple. There are a several of different methods depending on the data you want. Example A) and B) below return page 'meta-data'. Example C) below returns data on the page itself, either from within specific page sections or from templates used on the page.

A) A table of page meta-data;

The 'parser function' syntax of the DPL ({{#dpl:...) gives the cleanest looking code, and is used below for that reason. However, the regular <DPL> syntax works in an identical way but with different layout.

{{#dpl:
  |category       = Country
  |count          = 10
  |mode           = userformat
  |addauthor      = true
  |addpagesize    = true
  |addpagecounter = true
  |addfirstcategorydate = true
  |userdateformat       = d-m-Y
  |listseparators = 
    {¦ class="sortable"
      \n! 
      \n! Date
      \n! Name
      \n! Author
      \n! Views
      \n! Size
    \n¦-,
      \n¦ align="right" ¦ %NR%
      \n¦ align="right" ¦ %DATE%
      \n¦ align="left"  ¦ [[%PAGE%]]
      \n¦ align="left"  ¦ [[User:%USER%¦%USER%]]
      \n¦ align="right" ¦ %COUNT%
      \n¦ align="right" ¦ %SIZE% B,
    \n¦-\n,
    ¦}
}}

Gives;

Date Name Author Views Size
1 02-09-2007 Nig1 Gero  %COUNT% 166 B
2 02-09-2007 Nig2 Gero  %COUNT% 166 B
3 02-09-2007 Nig3 67.41.66.71  %COUNT% 174 B
4 03-09-2007 Nig4 67.41.66.71  %COUNT% 198 B
5 05-09-2007 Category:CountryA 67.41.66.71  %COUNT% 301 B
6 05-09-2007 Category:CountryB 67.41.66.71  %COUNT% 301 B

The key to understanding how this works is;

  1. understand DPL basics (link?),
  2. understand table syntax, and
  3. understand the listseparators parameter.

Once you understand these things you will understand the above DPL.

B) The same table of page meta-data using the 'table' parameter;

I wish I knew how to do this...

The 'table' parameter is designed to create tabular output for elements which come from an include statement. So you would have to use a surrogate template ('phantom template') which could use the %variables%. But this works only if there exists a template which each of your article uses exactly once. So, normally you will have to use the approach shown above .
Gero 15:45, 18 September 2007 (CEST)
Can you show us how would it would look? (Assuming we had a template that was used in each page exactly once). --Dmb 21:29, 20 September 2007 (CEST)

C) A table of page section or template data;

See Test table.

I try to generate table formatting with DPL but it looks weird - to hell with the syntax!

Indeed, complex queries can be somewhat tricky. But this is not only a problem of DPL. MediaWiki is quite sensitive to blanks and linefeeds and half of your problems will probably come from there.

There is a simple trick how you can DEBUG your DPL script:

Use a resultsheader and a resultsfooter to enclose all DPL output in pre/nowiki tags like this:

<dpl>
  resultsheader=<pre><nowiki>
  resultsfooter=</nowiki></pre>
  titlematch=Nig%
  include=%1[300]
  format={|class=wikitable\n!article\n!beginning\n|-,\n[[%PAGE%|%TITLE%\n,\n,\n|}
</dpl>

You can also simply set debug=5 to achieve the same effect.

If we execute the above query (without the debug header/footer) the result will be deeply unsatisfactory:

[[Nig1|Nig1 [[Nig2|Nig2 [[Nig3|Nig3 [[Nig4|Nig4 [[Nigunda Test|Nigunda Test Nigunda Test History - Chapter Sequence in the article doesn´t matter for DPL .. [[Nigunda|Nigunda some facts about religious groups in Nigunda; some other facts about religious groups in Nigunda;[[Nigeria|Nigeria
Main article: History of Nigeria
See also: Nigerian military juntas of 1966-1979 and 1983-1998
More than 2,000 years ago. the Nok..→
article beginning

But why?


With our little trick we can watch the output of DPL which would normally be immediately rendered by the wiki parser:

{{Extension DPL}}{|class=wikitable
!article
!beginning
|-
[[Nig1|Nig1]]


[[Nig2|Nig2]]


[[Nig3|Nig3]]


[[Nig4|Nig4]]


[[Nigunda Test|Nigunda Test]]

Nigunda Test History - Chapter  Sequence in the article doesn´t matter for DPL ..


[[Nigunda|Nigunda]]

some facts about religious groups in Nigunda; some other facts about religious groups in Nigunda;


[[Category:Tag_Event2]]

[[Nigeria|Nigeria]]

:<div class="noprint">''Main article: [[History of Nigeria|History of Nigeria]]''</div>
:<span class="boilerplate seealso">''See also: [[:Nigerian military juntas of 1966-1979 and 1983-1998|Nigerian military juntas of 1966-1979 and 1983-1998]]''</span>
More than 2,000 years ago. the [[Nok]]  [[Nigeria#History|..→]]

|}

And now we see: After the |- the next table row does not start with a '|'; and, apart from that, there is no "end of row" after each article. Now it is easy to correct the DPL query:

<dpl>
  titlematch=Nig%
  include=%1[300]
  format={|class=wikitable\n!article\n!beginning\n|-,\n|\n[[%PAGE%|%TITLE%]],\n|-,\n|}
  secseparators=\n|\n,
</dpl>

.. and we get the desired result:

article beginning

Nig1

Nig2

Nig3

Nig4

Nigunda Test

Nigunda Test History - Chapter Sequence in the article doesn´t matter for DPL ..

Nigunda

some facts about religious groups in Nigunda; some other facts about religious groups in Nigunda;

Nigeria

Main article: History of Nigeria
See also: Nigerian military juntas of 1966-1979 and 1983-1998

More than 2,000 years ago. the Nok ..→


In our "debugger" it looks like this:

{{Extension DPL}}{|class=wikitable
!article
!beginning
|-
|
[[Nig1|Nig1]]
|
|-
|
[[Nig2|Nig2]]
|
|-
|
[[Nig3|Nig3]]
|
|-
|
[[Nig4|Nig4]]
|
|-
|
[[Nigunda Test|Nigunda Test]]
|
Nigunda Test History - Chapter  Sequence in the article doesn´t matter for DPL ..

|-
|
[[Nigunda|Nigunda]]
|
some facts about religious groups in Nigunda; some other facts about religious groups in Nigunda;


[[Category:Tag_Event2]]
|-
|
[[Nigeria|Nigeria]]
|
:<div class="noprint">''Main article: [[History of Nigeria|History of Nigeria]]''</div>
:<span class="boilerplate seealso">''See also: [[:Nigerian military juntas of 1966-1979 and 1983-1998|Nigerian military juntas of 1966-1979 and 1983-1998]]''</span>
More than 2,000 years ago. the [[Nok]]  [[Nigeria#History|..→]]
|-
|}

Where can I talk about DPL?

Try here;

Using multiple categories with phantom template

I am absolutely indebted to the work on DPL. I pulled my hair out for 2 days trying to figure out a way to do this. One thing I can't figure out is using a phantom template with multiple categories separated by | will only return results from the category listed first. I have:

{{#dpl:
|category=Maintenance 2007 Week 41|Maintenance 2007 Week 42
|include={Infobox Maintenance}:date:start:end:page
|count=8
|table=class=maint,-,Date,Start,End,Title
}}

It only will display the output (correctly - date, start, end, page) from whichever category I list first, although it does it correctly. Is there anything I can do to fix this?

Here is one of my call to Infobox Maintenance in Category:Maintenance 2007 Week 42

{{Infobox Maintenance
|title=Scheduled Maintenance on hosting environment
|date=10/17/2007
|start=4:00 AM
|end=8:00 AM
|description=blablah
}}
I think your problem lies in the pipe symbol. If you use the parser function syntax like you did in your first query the mediawiki parser will grab each '|' and will think it found the beginning of a new parameter. Try to escape the | by using {{!}} and you probably will get the correct result. Apart from that problem I wonder why you don´t get an error message. I think I will have a look at that. Gero 19:48, 15 October 2007 (CEST)
I had a look at the code and found that parameters which do not contain a "=" sign are silently ignored. In the next release there will be a warning in such situations. This should be enough to draw your attention to the pipe symbol, I guess.
A last remark: This document is the wrong place for problem reports. Please reply after you solved your problem and then I will remove the entry here. We use the Issue documents for problem reports. Gero 20:12, 15 October 2007 (CEST)
That works perfectly! Thanks for the quick response for a project that I have been under pressure to complete. I wasn't sure where to place the question. I assumed there was--Xigxag 21:28, 16 October 2007 (CEST) a problem with my syntax usage, not an issue with the extension. Thanks for the help and your hard work. --Xigxag 03:49, 16 October 2007 (CEST)
Another question - How would I go about suppressing the dpl no results warning message when using in the context above? I use |noresultsheader= but it doesn't seem to work.
use debug=1 or put a html comment (or a non breaking space nbsp;) directly after the noresultsheader= clause. Gero 08:43, 16 October 2007 (CEST)
Ah great. Things are looking quite nice now. I am going to look into using the calendar in the future. Thanks again. --Xigxag 21:28, 16 October 2007 (CEST)

Can DPL be used to post text based on category of current page?

I would like to print different output depending on the category of the current page. For example, if the current page is in category "able", "baker" should print, otherwise "charlie". --C4duser 19:48, 22 November 2007 (CET)


DPL can easily be used for that. title is filled with the current FULLPAGENAME and [no]resultsheader is used to create the output. Care should be payed to the fact that we must accept the current page as part of the query result (se skipthispage).

<nowikli>
  {{#dpl:title={{FULLPAGENAME}}|skipthispage=no|category=able|resultsheader=baker|noresultsheader=charlie}}
</nowiki>


How would I code a DPL tag be used to post a category list of when the article was created/updated for the current month

I would like to display all articles created and/or modified (updated) for the {{currentmonth}}. Can this be done? ... if {{currentmonth}} can't be used, how would I code a specific month (i.e., date=May%) to give me the result?

I need to use a comma in my regexp but DPL uses the comma as a separator ..

Use \x2c in yopur regexp. The hex code 2c (dec. 44) is equivalent to a comma within a regular expression.

Can DPL be used to create statistics per user?

I would like to use DPL to create information on a given user, as follows:

  • Total number of edits for all articles.
  • Earliest edit date for all articles.
  • Total number of articles edited.

Is this possible? If so, could you give an example.

Thanks.

--C4duser 16:02, 31 December 2007 (CET)


Have a look at the scattergram which I put on the homepage of this wiki (see Scatter Demo 2). You might use a similar approach.

Gero 09:42, 2 January 2008 (CET)

Can DPL be used to create a subcategory listing with articles listed under their category

If I've got a category Colors with sub categories, Greens and Red, How can I automatically get a listing as follows

Colors

      Green
          Articles in category green
      Red
          Articles in category red

but using the category=*Colors in the DPL query.

This works if I use a pipe separated list of Categories category=Red|Green , but was hoping to avoid having to do this.

Any help, very much appreciated.

Mark

Reply

You can use nested queries. Create an outer query that returns all subcategories of 'Color' and use the format= parameter to output the result in a way that it can be used as an argument for the categories= parameter of the inner query.

Gero 14:06, 7 February 2008 (CET)

Example query, please?

I don't understand how to do this. Could you make an example query, assuming the category is "colors"? I'm not very good at this. You're the ones who said it was doable, now prove it :)

DPL Example 007 Gero 22:08, 9 March 2009 (UTC)

Thank you! Dafydd 07:54, 10 March 2009 (UTC)

My templates suddenly breaks

If the new parser is enabled (by default it is) then a lot of templates breaks, especially during calls to DPL. This will happen with release 1.12 (?) and later. The old parser can be used instead of the new one by a small addition to the file LocalSettings.php

$wgParserConf['class'] = 'Parser_OldPP';

There might be introduced ways to do this from the code DPL-code itselves. Jeblad 17:23, 13 April 2008 (CEST)

How do you reference include parameters in a format statement?

With an include line like this:

include = {my template}foo:bar:blat

how do you reference the values of foo, bar, and blat in a format statement? I see how to do it in a tablerow statement (with %%) but this doesn't work with format.

It would be helpful if the answer were documented here or here.

--Maiden taiwan 03:16, 1 May 2008 (CEST)

Reply

Currently there is no way to do this. That´s why it isn´t documented ;-)

I know that this would be quite a valuable feature to have but I do not have time for implementation. It should not be too hard to add this feature; I guess that for a person with some php experience it could be done in one day (but not in one hour ...) If you are going to change the code: please make sure that you use the sources from the latest version (1.72) as a starting point. Good luck! Gero 16:25, 1 May 2008 (CEST)

Sorting by the value of a template parameter?

Can DPL order its results based on the value of a template parameter? For example, suppose we have Template:Book:

This book is {{{title}}} written by {{{author}}}.

Can DPL produce a list of all articles that use this template, sorted by author?

--Maiden taiwan 20:36, 9 August 2008 (CEST)

Another sorting question: this time by value of phantom template

I want to have a DPL output that is ordered by the value of what is pulled in from a template with the include= syntax. In a set of articles included in one category I have placed a phantom template with meta data information in it. I want to pull that information out and then order the list by that information. For instance:
<dpl> category=dissertations include={Dissertation info}:date format=,# [[%PAGE%]]: ,\n, </dpl>

This produces a list with the date after each page name, but I want the list given in order by that date. Is this possible? If so, how?

Marcusperman 00:12, 28 January 2009 (UTC)

Using DEFAULTSORT or other sort key to order results

I have a problem with lists of people, as alphabetical sorting (titlewithoutnamespace) is by page name and not by sort key. Listing them by first name works for very short lists, but as soon as there's more than 5-10 names we really need to sort by last name (see "Eksempel 4" for an example). The most practical solution would be to use DEFAULSORT, sorting by that key if it exists, and alphabetically by pagename if there is no DEFAULTSORT key. Is there any way to achieve this now, or if not, would this be possible in the not so distant future? I'm not up to writing code for something like thay myself, but I imagine that this would be a problem for others too. Cnyborg 02:18, 12 August 2008 (CEST)

There is a solution for your problem which already works with the current DPL version, see Sort articles on people by last name! Gero 16:45, 15 August 2008 (CEST)

Random pieces of one page

Is it possible to display random pieces of text from one page as a DPL result? For sure they must be marked somehow (may be as chapters or list elements). I know that this is possible for a random set of pages for one category using the include parameter. --Silversurfer 13:49, 22 August 2008 (CEST)

Solved for me. I use the RandomArea Mediawiki extension. --Silversurfer 18:48, 5 September 2008 (UTC)
Indeed, this task is not well suited for DPL. DPL comes into the game when you want to pick content from more than one page. Gero 15:59, 12 September 2008 (UTC)
Please, how did you combine randomArea and DPL? --Neodimio 09:33, 12 February 2009 (UTC)
I don´t think they were combined at all. Gero 23:18, 13 February 2009 (UTC)

url/dynamic

Is it possible to parse variables into a page that uses DPL:includetrim?. URL Example:
http://semeb.com/dpldemo/index.php?title=Test_includetrim&nottitlematch=Random Chapter Content

--Messiah 14:12, 28 November 2008 (UTC)

How do you reference include parameters in a format/tablerow statement into a template?

With an include line like this:

include = {my template1}:%PAGE%:%TITLE%:foo1:foo2:foo3

how do you reference the values in a format/tablerow statement into a {my template2}? I see how to do it in a format statement, I can divide one info about one page:

include = {my template1}:foo1
format=, {{my template2|faa1=%TITLE%|faa2=,}},

if I need more info about one page, then I can use tablerow statement:

include = {my template1}:%PAGE%:foo1:foo2:foo3
table =,-,link to page, foo1, foo2, foo3
tablerow = %%,%%,%%,%%

but I would like to use more info about one page into {my template2}:

include = {my template1}:foo1:foo2:foo3
format=, {{my template2|faa1=%TITLE%|faa2=%foo1%|faa2=%foo1%|faa3=%foo2%|faa4=%foo3%}},

Are there any ideas?

--Bilardi 10:47, 22 January 2009 (UTC)

Reply

I am afraid your request is too complicated for the table statement. See Test table for the maximum you can achieve with the table command.

I suggest to use both templates within the include statement instead.

include = {my template1}.myFormat,{my template2}.myFormat

You will have to provide two phantom templates called 'my template1.myFormat' and 'my template1.myFormat'. Within these templates you can provide table row formatting according to your own preferences. There are some examples for this in the manual. The row break can be handled in the format statement (third parameter), start and end of the table must be given in the first and in the fourth parameter of the format statement.

This kind of formatting always becomes a little tricky if you cannot guarantee that both templates are used exactly once (or at least once) in each article. Also the sequence in which these templates appear in your article should always be the same ... Good Luck!

Gero 16:04, 23 January 2009 (UTC)

All articles that transclude from the main namespace?

Can DPL produce a list of all articles that transclude from a given namespace? For example, I want a list of all articles that contain a line like this:

{{:...}}

i.e., that transclude content from the main namespace. It should not be recursive. Maiden taiwan 15:57, 3 February 2009 (UTC)

tablesortcol ignoring identical values?

I'm using tablesortcol to change the default sort from the first column. It appears that if any items in the column have the same value, the other page(s) are ignored when the table is generated. I read the manual entry for tablesortcol and there does not seem to be any reference to this behavior. Billm 15:48, 24 March 2009 (UTC)

includematch

Hi! I want to select pages which contains 'hello world' in Example chapter. As i understand 'includematch' can help me, but i don't understand how to make it... I tried to paste expression from examples and always got PHP errors (about delimiter or offset). I just want to select pages which contains 'hello world' to add them to the table. What do i need? --Maaboo 13:37, 24 April 2009 (UTC)

Used and unused images

Is there a way to select images that are used (il_to NOT NULL, linked to by any other page)) or unsed? --Subfader 00:50, 29 April 2009 (UTC)

Selection by MIME types?

Is it possible to select file page titles by img_major_mime or img_minor_mime? E.g. a list of images (img_major_mime=image) or a list of PDF files (img_minor_mime=pdf). --Subfader 00:50, 29 April 2009 (UTC)

Last edits which are not page creations?

How to list pages which were recently edited by a specified user but excluding those which were created by that user but not edited afterwards? I'm using this atm:

|modifiedby=UserName
|ordermethod=lastedit
|order=descending

So: Do not don't count page creation as edit. Any ideas? --Subfader 00:50, 29 April 2009 (UTC)