How to work with wiki-to-print?
Wikis are great for (a-sync) collaborative writing and editing, which is why the MediaWiki software is a part of wiki-to-print. Alongside this, concepts such as transclusion are useful in allowing you to collate a publication from many differently authored pages by referring to them in hypertext. Simply put, transclusion is including a part of a document into another one by hypertext reference, rather than copying it. Pages (or parts of them) can be transcluded into another wiki page, as so:
{{:name of page to be transcluded}}
Wiki-to-print uses the Pdf
namespace to make an environment in which PDFs can be written, edited and designed by multiple people simultaneously. After creating a wiki-to-print environment in the Pdf
namespace, some useful wiki-to-print features are automatically added that allow you to render a wiki page into a HTML page and PDF document.
So once you have made a new wiki-to-print environment, a range of pink buttons are added to the navigation bar, which include:
CSS!
Here you can add the style for your print layout.
The Talk pages in the Pdf
namespace are turned into CSS stylesheets for each particular wiki-to-print environment. So, once you have created a new wiki-to-print environment, an empty CSS stylesheet is also made.
View HTML
Here you can inspect the HTML and CSS of your page.
If you want to preview the content as HTML, you can do this by clicking this button. This can be helpful to do when, for example, something unexpected happened in your layout and you want to figure out what is happening. You can also see the CSS alongside the rendered HTML in the same browser window.
View PDF
Here you can preview your PDF.
Clicking this button allows you to preview the content as a PDF in a new browser tab. Here, your content and the page layout you specified in your CSS are rendered by the JavaScript library Paged.js to look like a PDF. If you are satisfied with this, you can export the PDF from this browser tab simply by pressing ctrl/command + p
. If you have any problems seeing the layout, it's useful to check that your content and CSS is written correctly by viewing and inspecting how the HTML is rendered.
Update text
Here you can update your text after making changes.
Any changes to text in your wiki-to-print environment (such as in content, or CSS) need to be updated before you can view them in the PDF. This also applies to any pages that are transcluded into your wiki-to-print environment. Clicking this button opens a new browser tab, as a sign that you have now updated the text. You can safely close it afterwards.
Update Media
Here you can update your text + media after making changes.
Any changes to media in your wiki-to-print environment (such as new images you upload) need to be updated before you can view them in the PDF. This also applies to any pages that are transcluded into your wiki-to-print environment. Clicking this button opens a new browser tab, as a sign that you have now updated the media. You can safely close it afterwards.