Dotta's Mediawiki Tips: Difference between revisions

From wizzypedia
Jump to navigation Jump to search
No edit summary
No edit summary
Line 5: Line 5:
=== CSS For Templates ===
=== CSS For Templates ===


Look at how elegant this <pre>Image</pre> template is on Mediawiki [https://www.mediawiki.org/w/index.php?title=Template:Image&action=edit Template:Image on Mediawiki]. They also load custom CSS just for this template, which is handy.
Look at how elegant this <tt>Image</tt> template is on Mediawiki [https://www.mediawiki.org/w/index.php?title=Template:Image&action=edit Template:Image on Mediawiki]. They also load custom CSS just for this template, which is handy.


=== Dynamic Gallery ===
=== Dynamic Gallery ===


If you want to have a dynamic gallery, you can't use the typical <pre>gallery</pre> tag, you have to do it like this:
If you want to have a dynamic gallery, you can't use the typical <tt>gallery</tt> tag, you have to do it like this:


<pre>
<pre>

Revision as of 13:52, 6 July 2022

Templates

CSS For Templates

Look at how elegant this Image template is on Mediawiki Template:Image on Mediawiki. They also load custom CSS just for this template, which is handy.

Dynamic Gallery

If you want to have a dynamic gallery, you can't use the typical gallery tag, you have to do it like this:

{{#tag:gallery|
{{Test/Dotta/GalleryItem}}
|mode=packed-hover|caption=foo|
}}

More generically, this is the syntax for using tags with the parser functions src