Libregamewiki:DatabaseQuery

From Libregamewiki
Jump to navigation Jump to search

DatabaseQuery is an extension used by LibreGameWiki. It allows to make queries to the database of games. It is meant to be used on pages like List of Games and New games and releases.

Its source code can be found at [1].

Usage[edit]

This extension can be used by inserting the following code into a wiki page:

{{#databasequery:<query>|<table style>|<column header template>|<row template>|<count or filter>}}

Parameters:

  • query: Type of the query. Either recentreleased for recently-released games or gamelist for a list of games
  • table style: Style for the table. Commonly used are wikitable and sortable. If empty, uses the default style
  • column header template: Name of the template to be used to render column headers (excluding the Template: prefix)
  • row template: Name of the template to render each row (excluding the Template: prefix). The names of the columns are used as parameter names here
  • count or filter: Depends on the query type
    • For recentreleased: Number of entries in output
    • For gamelist: Filter of the game name.
      • X% filters all games that start with letter X.
      • <X filters all games that start with a letter “smaller than” X

Recommended column header and row templates[edit]

In LibreGameWiki, the following templates for column header template are available:

And for row template:

Author[edit]

This extension comes from nikitools and is authored by Hendrik Brummermann.