Vorlage:Rating/Doku
This template is designed to provide an image rating system, defaulting to stars. The template accepts ratings of up to ten, with more than six appearing reduced in size.
When to use this template
The template works with whole and half ratings (e.g. 0, 0.5, 1, 1.5, etc.). Other rating fractions (e.g. 3.2, 7.25) will be rounded, and the page on which the template resides will be inserted into the maintenance category Category:Pages with incorrect use of Rating template. Use |score=
to provide explanatory text for ratings that the original source does not express in whole or half increments.
Please only use this template if the rating was originally expressed with the images used. For example, if a reviewer awards something a rating of "4" (expressed in digits not stars) on a scale of 5, you should simply write it as "4" or "4/5" in your article, depending on how it is presented by the source. Do not use {{rating|4|5}} where the source does not use stars, because it is inaccurate and misleading. Note that ratings on a scale of 10 can be hard to read if expressed visually with images.
Parameters
Default
These are the only parameters you need to show star ratings, the default symbols.
- The first unnamed parameter is the number of the rating received.
- The second unnamed parameter is optional, and is the maximum possible for the rating system. This will show empty or blank elements for the remainder above the rating, and changes the text in the tooltip to add "/x".
TemplateData
TemplateData for Rating
A template to provide an image rating system
Parameter | Beschreibung | Typ | Status | |
---|---|---|---|---|
Received | 1 | Number of stars (or other images) received | Nummer | erforderlich |
Possible | 2 | Total possible stars (or other images; defaults to parameter 1) | Nummer | optional |
Score | score | Text displayed when hovering over the rating | Zeichenfolge | optional |
Full alternate | full | Alternate image for a full star, without the File: prefix
| Zeichenfolge | optional |
Half alternate | half | Alternate image for a half star, without the File: prefix
| Zeichenfolge | optional |
Empty alternate | empty | Alternate image for an empty star, without the File: prefix
| Zeichenfolge | optional |
Rating symbol | rating | Unit for alternate images
| Zeichenfolge | optional |
Plural rating symbol | rating-plural | Plural form of the rating parameter if it is not just adding an "s" | Zeichenfolge | optional |
Images size | size | Size of the images, in pixels
| Zeichenfolge | optional |
See also
- {{Rating-Christgau}} (for ratings by music critic Robert Christgau)