Template Help: Difference between revisions
More languages
More actions
mNo edit summary Tags: Reverted Visual edit |
Added common issues section |
||
(4 intermediate revisions by the same user not shown) | |||
Line 12: | Line 12: | ||
The page creation interface will then open. Unless you want to edit the wikitext directly, you need to select the '''pencil icon''' on the <u>right of the page</u>, and choose '''<nowiki/>'Visual Editing''''. Then, the visual editor will load and after a few seconds you will be ready. |
The page creation interface will then open. Unless you want to edit the wikitext directly, you need to select the '''pencil icon''' on the <u>right of the page</u>, and choose '''<nowiki/>'Visual Editing''''. Then, the visual editor will load and after a few seconds you will be ready. |
||
Alternatively, you can select the <u>top option</u> in the search box, and you will also be prompted to create a page at the <u>very top of the search results</u>. If you click the link to the page there, you should enter the visual editor directly. |
Alternatively, you can select the <u>top option</u> in the search box, and you will also be prompted to create a page at the <u>very top of the search results</u>. If you click the link to the page there, you should enter the visual editor directly. |
||
⚫ | |||
=== Inserting the template === |
=== Inserting the template === |
||
To insert the template, you have to press the '''<nowiki/>'Insert'''' button in <u>the toolbar</u>. In the <u>drop-down menu</u>, along the options to insert images & media and tables, you will see an option saying '''<nowiki/>'Template''''; click it and a template search box will pop up. |
To insert the template, you have to press the '''<nowiki/>'Insert'''' button in <u>the toolbar</u>. In the <u>drop-down menu</u>, along the options to insert images & media and tables, you will see an option saying '''<nowiki/>'Template''''; click it and a template search box will pop up. |
||
⚫ | |||
[[File:Template search — infobox.jpg|thumb|346x346px|All of the infoboxes showing in the template search box]] |
[[File:Template search — infobox.jpg|thumb|346x346px|All of the infoboxes showing in the template search box]] |
||
[[File:Insert button menu.png|left|thumb|The 'Insert' drop-down menu; 'Template' is right in the middle]] |
[[File:Insert button menu.png|left|thumb|The 'Insert' drop-down menu; 'Template' is right in the middle]] |
||
In the search box you should search for ''"infobox"'', because all of our currently available templates are infoboxes. You will see five options. '''''<big>Do not select 'Infobox'</big>''''', because that is a template to create other infoboxes only. |
In the search box you should search for ''"infobox"'', because all of our currently available templates are infoboxes. You will see five options. '''''<big>Do not select 'Infobox'</big>''''', because that is a template to create other infoboxes only. |
||
[[File:Empty infobox settlement.png|left|thumb|A blank settlement infobox]] |
[[File:Empty infobox settlement.png|left|thumb|A blank settlement infobox]] |
||
[[File:Empty infobox player.png |
[[File:Empty infobox player.png|thumb|A blank player infobox]] |
||
In our case, ''<nowiki/>'Some Town''' is a town, so we ought to select '''<nowiki/>'Infobox Settlement''''. When you select, which infobox to insert, a big menu will appear, prompting you to input data into the infobox. The data includes the ''name'' of the settlement or player, ''date'' the settlement was founded, a ''picture'', etc. Input only what you want and what is required. |
In our case, ''<nowiki/>'Some Town''' is a town, so we ought to select '''<nowiki/>'Infobox Settlement''''. When you select, which infobox to insert, a big menu will appear, prompting you to input data into the infobox. The data includes the ''name'' of the settlement or player, ''date'' the settlement was founded, a ''picture'', etc. Input only what you want and what is required. |
||
Line 43: | Line 34: | ||
=== Can I put multiple infoboxes on one page? === |
=== Can I put multiple infoboxes on one page? === |
||
Absolutely! If, for example, you want to include a build infobox and an event infobox on one page describing an event, where the build in question was build — you totally can. One will just appear above/below the other and you can choose which one is which by dragging them around in the visual editor. If you just want to add a page to a category, but you don't want an infobox, you can do that by clicking the '''<nowiki/>'Category'''' label at the bottom of the page. |
Absolutely! If, for example, you want to include a build infobox and an event infobox on one page describing an event, where the build in question was build — you totally can. One will just appear above/below the other and you can choose which one is which by dragging them around in the visual editor. If you just want to add a page to a category, but you don't want an infobox, you can do that by clicking the '''<nowiki/>'Category'''' label at the bottom of the page. |
||
== Common issues & fixes == |
|||
=== My infobox doesn't show my picture D: === |
|||
[[File:Broken infobox rorhl.png|thumb|The infobox in question]] |
|||
In the image field of an infobox functions the way regular wikitext does, meaning that any text that you will put in will display like wikitext. This means, that is you put just <code>my picture.png</code> in there, it will just render the text ''"my picture.png"''. An example of this was [[User:Rorhl|rorhl's]] infobox, where he specified the name of the picture (<code>Rorhl rorhl.png</code>), but it didn't render in. So then, how do you put images there? |
|||
As I said earlier, infoboxes treat all text as wikitext, and in wikitext, an image is '''just a wiki-link to the image''' file. Links are written as a page name or a URL to a website, surrounded by square brackets, for example, <code><nowiki>[[https://moxiecraft.org/wiki]]</nowiki></code> will lead to the main page of the wiki. Fun fact: if you begin typing two square brackets in the visual editor, the link editing interface shows up automatically. |
|||
All files on the wiki are located in the <code>File:</code> namespace, so in order to link your image, you need to type your image's name, with <code>File:</code> <u>prepended at the beginning</u>, all <u>surrounded by double square brackets</u>. Or, to again use [[User:Rorhl|Rorhl's page]] as an example, he would need to type <code><nowiki>[[File:Rorhl rorhl.png]]</nowiki></code> to insert that image. |
|||
However, I recommend adding an extra piece of data to the link! When you insert your image, you might notice that it's humongous and takes up almost the whole page. That is because the wiki tries to insert your picture in its original size; you <u>need to change the size manually</u> to fit into the infobox. To do that, append <code>|300px</code> to the '''end of your file name before the square brackets'''. The number specifies the width of the picture. 300 pixels works the best most of the time, because the image then fits the entire infobox, but you can change it if you want. With the aforementioned example — the final result looks like <code><nowiki>[[File:Rorhl rorhl.png|300px]]</nowiki></code>. |
|||
=== Why do dates not display properly? === |
|||
[[User:Rorhl|Rorhl's page]] is a good example because it displayed these two issues simultaneously: the image was covered in the previous section, here I will talk about dates. |
|||
On the wiki, all infoboxes have '''separate fields''' for the day, month and year. You can see that on the screenshots of the infobox creation menu above. This is done to make sure that all dates look the same, so that nobody is confused about what time it is, because ''Americans decided to be weird and arrange their dates like '''no other country <u>in the world</u>''''', leading to confusion for everyone that is '''not American'''. |
|||
To input your date, you just need to fill out the <u>day, month and year separately</u> from one another, and it will be displayed correctly. The format that is used on the wiki is <code>DD.MM.YYYY</code>, and that is how all dates should appear if they are input properly. |
|||
[[Category:FAQ]] |
[[Category:FAQ]] |
Latest revision as of 20:03, 6 August 2025
Introduction
On the Moxiecraft Wiki, all pages are put into categories, in order for the wiki to remain organised. To achieve that we created a few templates, that should be pasted on your page, that will then also make most of our pages easily understandable. These templates are known as infoboxes — they display a couple snippets of information about the topic, that they are describing. For example, Infobox Player would display a picture of the player, their Minecraft username or where they reside on Moxiecraft.
You can find infoboxes on many pages, but more often then not, you will want to add an infobox to a page about your town or about yourself, like many other towns and people have done. Some good examples are Potato Valley, SiOtter and Clifftown.
How do I add a template?

Creating a page
To add a template to a page, you first need to create a page. To create a page, search for its name using the search button on the left. Put in your desired page's name like, let's say "Some Town", and select the bottom option, aka. the one that says 'Create or edit page'.

The page creation interface will then open. Unless you want to edit the wikitext directly, you need to select the pencil icon on the right of the page, and choose 'Visual Editing'. Then, the visual editor will load and after a few seconds you will be ready. Alternatively, you can select the top option in the search box, and you will also be prompted to create a page at the very top of the search results. If you click the link to the page there, you should enter the visual editor directly.
Inserting the template
To insert the template, you have to press the 'Insert' button in the toolbar. In the drop-down menu, along the options to insert images & media and tables, you will see an option saying 'Template'; click it and a template search box will pop up.



In the search box you should search for "infobox", because all of our currently available templates are infoboxes. You will see five options. Do not select 'Infobox', because that is a template to create other infoboxes only.


In our case, 'Some Town' is a town, so we ought to select 'Infobox Settlement'. When you select, which infobox to insert, a big menu will appear, prompting you to input data into the infobox. The data includes the name of the settlement or player, date the settlement was founded, a picture, etc. Input only what you want and what is required.
When you think you are finished, press 'Insert' in the top-right corner of the window. Now, the template will appear at the top-right of the wiki page. You can always go back to it and edit/add/remove data by clicking on the infobox in the visual editor.
Putting the page in the correct category
Once you put an infobox onto your page and saved the changes, your page will be automatically added to the corresponding category. So, for example, our 'Some Town' page will automatically get added to the settlements category, as indicated by a pill-shaped button at the bottom of the article.
Some options in the infobox also add pages to separate categories. For example, if I indicate that 'Some Town' has a warp, the page will automatically get added to the warps category, or if I say that a player is an admin, then the page gets added to the admins category too.
You can also manually add categories to your pages. In the visual editor, just press on the 'Category:' label at the bottom and a pop-up will appear, prompting you to add a category for the page. This way you can add as many categories as you want to the page!
Can I put multiple infoboxes on one page?
Absolutely! If, for example, you want to include a build infobox and an event infobox on one page describing an event, where the build in question was build — you totally can. One will just appear above/below the other and you can choose which one is which by dragging them around in the visual editor. If you just want to add a page to a category, but you don't want an infobox, you can do that by clicking the 'Category' label at the bottom of the page.
Common issues & fixes
My infobox doesn't show my picture D:

In the image field of an infobox functions the way regular wikitext does, meaning that any text that you will put in will display like wikitext. This means, that is you put just my picture.png
in there, it will just render the text "my picture.png". An example of this was rorhl's infobox, where he specified the name of the picture (Rorhl rorhl.png
), but it didn't render in. So then, how do you put images there?
As I said earlier, infoboxes treat all text as wikitext, and in wikitext, an image is just a wiki-link to the image file. Links are written as a page name or a URL to a website, surrounded by square brackets, for example, [[https://moxiecraft.org/wiki]]
will lead to the main page of the wiki. Fun fact: if you begin typing two square brackets in the visual editor, the link editing interface shows up automatically.
All files on the wiki are located in the File:
namespace, so in order to link your image, you need to type your image's name, with File:
prepended at the beginning, all surrounded by double square brackets. Or, to again use Rorhl's page as an example, he would need to type [[File:Rorhl rorhl.png]]
to insert that image.
However, I recommend adding an extra piece of data to the link! When you insert your image, you might notice that it's humongous and takes up almost the whole page. That is because the wiki tries to insert your picture in its original size; you need to change the size manually to fit into the infobox. To do that, append |300px
to the end of your file name before the square brackets. The number specifies the width of the picture. 300 pixels works the best most of the time, because the image then fits the entire infobox, but you can change it if you want. With the aforementioned example — the final result looks like [[File:Rorhl rorhl.png|300px]]
.
Why do dates not display properly?
Rorhl's page is a good example because it displayed these two issues simultaneously: the image was covered in the previous section, here I will talk about dates.
On the wiki, all infoboxes have separate fields for the day, month and year. You can see that on the screenshots of the infobox creation menu above. This is done to make sure that all dates look the same, so that nobody is confused about what time it is, because Americans decided to be weird and arrange their dates like no other country in the world, leading to confusion for everyone that is not American.
To input your date, you just need to fill out the day, month and year separately from one another, and it will be displayed correctly. The format that is used on the wiki is DD.MM.YYYY
, and that is how all dates should appear if they are input properly.