Difference between revisions of "14 January 2009"

From Organic Design wiki
(dynamic export queriesd)
m (braces in wrong place)
Line 21: Line 21:
 
Sandbox
 
Sandbox
 
}}
 
}}
}}
 
</td></tr></table>
 
 
}}
 
}}
  
Line 35: Line 33:
  
 
We intend to maintain a number of "article packages" in this way in the [[wiki article packages]] article.
 
We intend to maintain a number of "article packages" in this way in the [[wiki article packages]] article.
 +
</td></tr></table>
 +
}}

Revision as of 00:23, 20 January 2009

Warning.svg This is a blog item that needs to be converted to the new Bliki format


Automatic article export lists

We have a lot of collections of articles which we tend to re-use a lot on many wikis in the field. We don't want to use cross-wiki transclusion because we don't want these wikis to rely on external content for their day-to-day use, so we needed a simple way to maintain these collections and export them when needed.

We've been working on the Packages extension for a while to solve this problem, but in the mean time I created Template:Export which offers a simple interface to the Special:Export functionality. Here's an example,

This wikitext

{{export:
News
Help
Sandbox
}}
        

Produces this export button

The list of articles to be used by the export doesn't have to be fixed, a DPL query or other kind of dynamic operation can be used to generate it. The query must be made to specify the results be simple textual names separated by newline characters as in the following example which exports all articles containing the {{book}} template.

The wikitext: {{export|{{#dpl:uses=Template:Book|format=,%NAMESPACE%:%TITLE%\n,,}}}}


The resulting export button:


We intend to maintain a number of "article packages" in this way in the wiki article packages article.