cultura italiana

Templates

Templates are a way to insert elements commonly used among your pages by reference, and they are usually invoked with one or more parameters which will be wrapped or transformed by the template in various ways. Besides all the Wikipedia's or Mediawiki's templates which can be used or imported if missing, here are some additional templates specifically created for this platform. To use them, go to "Edit source" in the top menu, and insert the wiki text as shown below.


text highlight

{{CI text highlight| text to highlight }}

produces:

text to highlight


inline logo

{{CI inline logo}}

produces:

Cultura italiana


notice box

{{CI notice box | some notice }}

produces:

some notice


pdf thumbnail

{{CI pdf thumbnail | Knuth-plass-breaking.pdf |  Breaking paragraphs into lines | clear after = true }}

produces:

Knuth-plass-breaking.pdf
Breaking paragraphs into lines

it shows a thumbnail of the first page of the pdf, with a direct link to it: it expects filename and optionally caption as unnamed arguments, plus a "clear after" argument, specifying whether we want to prevent subsequent elements to float (default is false), or alternatively a "clear" argument, specifying the actual value for the float css property.

Basically, if you want to show a series of pdf thumbnails as a column, you can omit both "clear after" and "clear" arguments, if you want to display the pdf thumbnails aside each other, you can use "clear after = false" or "clear = none". If you want let the text around to float on the left you can use "clear = right" (or "clear = left" if you want the text around floating on the right).

How it works/Templates/msupload insertpdf arrow.jpg

When using "clear after = false" or "clear = none" just remind to disable it for the last thumbnail otherwise the following page's section will float on the right of the element, which is usually an unwanted behavior.

Finally, since April 2021 this template can be inserted using WikiEditor following the instructions here (see picture on the right).


Accordion

{{CI accordion
|Why should I use this website? 
|Of course that's your choice ... 

|Why canapes tend to fall on the wrong side? 
|Because the specific weight of bread ... 

|Why should I wake up my sons so early to bring them at school ? 
|To prevent it grows some odd idea in their dreams...

}}


which produces the following

Why should I use this website?
Of course that's your choice ...
Why canapes tend to fall on the wrong side?
Because the specific weight of bread is less than ...
Why should I wake up my sons so early to bring them at school ?
To prevent it grows some odd idea in their dreams...
Why the specific weight of bread is less than ... ?
Because in a right triangle the area of the square whose side is the hypotenuse is equal to the sum of the areas of the squares on the other two sides

(except that last question-answer which is "a plus")

The accordion template (technically a Lua module) takes advantage of Dynamic components on the front-end, so basically you can add to your pages the equivalent of a paying wordpress plugin with just few lines of wiki text.



clear div

{{CI clear div }}


the latter does not show anything, but avoids text or elements to float if there are floating elements above, for instance using a floating image thumbnail (an image with floating text on left or right).