Jump to content

User:Radomianin/Photo credit box

From Wikimedia Commons, the free media repository

About

A personal credit box template for the use with my (own) photographs. It is currently available in English, German, Spanish, French and Polish. This template should be used directly below the general {{Information}} template, because it builds a special information box on its own; if we don’t add a blank line in between, the new box is visually merged with the {{Information}} box. Very nice!

Some hints about the implementation

  • Around the individual {{Information field}} entries we put a <table> ... </table> element. This table gets the same CSS classes and some other attributes as the regular {{Information}} template or as the {{Location}} template. Using these CSS classes allows the additional information fields to be merged visually with the main Information box, just as e.g. the {{Location}} templates does. It also enables some other functions – e.g. in mobile display on small screens the table automatically switches to a single-column display.
  • It would be wise to check from time to time whether the CSS classes and attributes used in the {{Location}} template have been changed; then it could be necessary to update this template accordingly.
  • The localization for the ‘Attribution’ field uses the same code as the {{Credit line}} template: {{int:wm-license-cc-attribution|}}<br/><small>({{I18n/Credit line}})</small>; so look out if that line in the {{Credit line}} template or if any of the subtemplates used there changes, because this may force us to update this template, too.

Template preview

This template {{User:Radomianin/Photo credit box}} is rendered as follows:

Attribution
(required by the license)
InfoField
© Radomianin / Wikimedia Commons / CC BY-SA 4.0
Using this image
InfoField
You can use this image file free of charge under the terms of the free license CC BY-SA 4.0. In particular, this means:
  • You must include the credit line (Attribution) given above in an appropriate place (next to the image, or in your list of image sources, etc.), to establish a clear and reasonable link between the image and the credit line. Please quote the credit line (Attribution) completely.
Editing this image
InfoField
  • If you want to edit this file for Commons, please upload it using a new file name. Use the template {{Derived from}} or {{Extracted from}} for this purpose. I ask you to preserve my original version of this file and to keep it easily accessible. Thank you!