DPL talk:Manual

From FollowTheScore
Revision as of 00:09, 10 May 2008 by Peptobismol (talk | contribs) (reply³)
Jump to: navigation, search

Counting Results

So which parameter(s) will give me a count of the number of pages that fit the criteria instead of the pages themselves? —Sledged (talk) 04:49, 29 November 2007 (CET)

I don´t understand your question. Give an example. Gero 08:47, 29 November 2007 (CET)

Let's take the search criteria in the example on the Main Page:
category=African Union member states
nottitlematch=Sudan
There are three pages that match this criteria, so I want the output:
3
instead of getting a list of those pages. I just want to count the number of pages that match the criteria. I thought I'd be able to specify that with the mode parameter, but that doesn't seem to be an option. —Sledged (talk) 15:40, 29 November 2007 (CET)


o.k. : use The %PAGES% parameter in the resultsheader. It will contain the correct value even if you use regular expression to filter template calls by the parameter values they use.
Gero 17:13, 29 November 2007 (CET)


Top Most Visited Pages ?

Is there a way with DPL to get the N "Top Visited Pages" during a specified period ? Ex: get the 10 most visited page since the begining of the week ?

Reply

I don´t think so. The page counter in the wiki database is not attached to the history. Using DPL you could make a snapshot of (say) the 200 pages with the highest usage rank plus those pages that were modified recently (although they may have low usage rates). If you do that regularly you could then use ploticus to generate a graph of incremental usages. Gero 19:09, 14 December 2007 (CET)

Add UserGroup criteria function?

Can you add a page list criteria by a User's user group? It would be a nice addition for groups to share files and communication. thanks.

Could you be more precise, please?

  • how should the command be named?
  • what exactly should it do?
  • what do you mean by 'user group'?
  • can you gove an example?
Gero 22:26, 6 May 2008 (CEST)

Hi, I'll be more clear..

Each user belongs to a user group like sysop, user, bureaucrat, or a custom named group like 'author'. Right now, you can list articles written by a user or by namespace like:

<DPL> createdby=Joe </DPL>

<DPL> namespace=something </DPL>


It would be useful to list articles by usergroup like; <DPL> byusergroup=sysop </DPL>


thanks.

Reply

Well, that is not too complicated and I think it is a useful feature. In the last time I try to motivate people to do such minor changes to DPL themselves. I always offer to test, document and integate the solution into the next release. The idea is that DPL is only then real open source if more than one person (i.e. me) is in contact with the sources. Are you capable of doing it or do you know somebody who could do it? Gero 19:12, 8 May 2008 (CEST)

reply reply

I'm good at hacking. Is there a manual for variables, classes, codes for DPL anywhere?

reply³

There is no technical documentation regarding the code so far. But there are useful inline comments. It is only the larger source file that you would need to change. The smaller one only deals with transclusion of contents. The larger source has three or four classes - some of which are rather huge but very straight forward. Parsing the input (i.e. checking parameters) takes a lot of lines .. I inherited the code and never found time to break those classes into smaller pieces. Maybe I should put that on my agenda. Gero 08:07, 9 May 2008 (CEST)

reply x 4

Ugh... I'm looking the variables for the mysql query right now and it's giving me a headache.