Vorlage:Ambox/Doku: Unterschied zwischen den Versionen

Removing the wikitable example and instead linking to the new how-to guide describing usage in wikitables and HTML tables.
imported>Davidgothberg
(Added text in heading about that this template is controlled by the CSS classes and that they can be used in a wikitable. And yeah, I am going to write up a how-to guide how to use the classes.)
imported>Davidgothberg
(Removing the wikitable example and instead linking to the new how-to guide describing usage in wikitables and HTML tables.)
Zeile 7: Zeile 7:
It is used to create ''article message box'' templates such as {{tl|wikify}} etc. It offers several different colours, uses default images if no image parameter is given and it has some other features.
It is used to create ''article message box'' templates such as {{tl|wikify}} etc. It offers several different colours, uses default images if no image parameter is given and it has some other features.


This meta template is just a thin wrapper for the <code>.ambox</code> CSS classes in [[MediaWiki:Common.css]]. The classes can just as well be used directly in a [[Help:Table|wikitable]], especially if special functionality is needed. See example further below.
This meta template is just a thin wrapper for the ambox CSS classes in [[MediaWiki:Common.css]]. The classes can also be used directly in a [[Help:Table|wikitable]], especially if special functionality is needed. See the [[Wikipedia:Ambox CSS classes|how-to guide]] for that.


'''Note:'''  
'''Note:'''  
Zeile 183: Zeile 183:




This template uses CSS classes for most of its looks, thus it is fully "skinnable".
This template uses CSS classes for most of its looks, thus it is fully skinnable.  
 
The CSS classes can also be used directly in a wikitable. Like this:
 
<pre>
{| class="ambox ambox-content"
|-
| class="ambox-image" | [[Image:Emblem-important.svg|40px]]
| Some text.
|}
</pre>
 
{| class="ambox ambox-content"
|-
| class="ambox-image" | [[Image:Emblem-important.svg|40px]]
| Some text.
|}
 


Internally this meta template uses HTML markup instead of wiki markup for the table code. That is the usual way we make meta templates since wiki markup has several drawbacks. For instance it makes it harder to use [[m:Help:ParserFunctions|parser functions]] and special characters in parameters.  
Internally this meta template uses HTML markup instead of wiki markup for the table code. That is the usual way we make meta templates since wiki markup has several drawbacks. For instance it makes it harder to use [[m:Help:ParserFunctions|parser functions]] and special characters in parameters.  
Zeile 208: Zeile 191:
=== See also ===
=== See also ===


* [[Wikipedia:Article message boxes]] - For more information on how and when to use this meta template.
* [[Wikipedia:Ambox CSS classes]] – Describes how to use the ambox CSS classes directly in [[Help:Table|wikitable]]s and [[HTML element#Tables|HTML tables]].
* [[Wikipedia:Article message boxes]] - The (proposed) style guideline for creating article message boxes.
* [[Wikipedia talk:Article message boxes]] - For discussion about these matters.
* [[Wikipedia talk:Article message boxes]] - For discussion about these matters.


Anonymer Benutzer