|
Tags: Reverted 2017 source edit |
Line 1: |
Line 1: |
| If you have server access, you can customize the PDF templates for your wiki. If your wiki is hosted in the ''BlueSpice cloud'', basic customizations can be made [[Manual:Extension/BlueSpiceUniversalExport/Customization|directly in the wiki]]. These instructions refer to the PDF single page export and the book export. Please note that the book export is only available in''BlueSpice pro''.
| | {{New}}{{New}} |
| | #[[File:portalflex-PT-savepage.png|thumb|dfsafsadf|alt=|center]] |
| | ##dsfsdfsdfsdf |
| | ##asfdsaffd |
| | ##sdfdsaf |
| | ###sdfsadfdsfdfsadfdsaf |
| | #safaf |
| | #dfsafsafsaf[[File:portalflex-PT-savepage.png|alt=|center|400x400px]]sadfsadfdsafdfaaaaaaaaaaav sadffffffffffffffs dafdsfsaf sadfsadfdsafdfaaaaaaaaaaav sadffffffffffffffs dafdsfsaf |
| | ##dfsadfsadfdsf |
| | #dsafsadfasdf |
|
| |
|
| == Directory paths for templates ==
| |
|
| |
|
| === Standard BlueSpice templates === | | =test= |
| *'''Common:''' extensions/BlueSpiceUEModulePDF/data/PDFTemplates/common
| | <bs:watchlist count="10" maxtitlelength="50" /> |
| *'''Single page:''' extensions/BlueSpiceUEModulePDF/data/PDFTemplates/BlueSpice
| | =tst2= |
| *'''Book:''' extensions/BlueSpiceUEModuleBookPDF/data/PDFTemplates/BlueSpice Book
| | hallo |
| | <headertabs /> |
|
| |
|
| {{Textbox|boxtype=important|header=|text=The '''Common''' directory contains common files such as: B. the page.css that defines the page margins.|icon=no}}
| | ==test == |
| | |
| === Safe directories for your own templates ===
| |
| The PDF templates may not be customized in the directories mentioned above. <u>An update will overwrite the changes!</u>
| |
| | |
| '''Examples of safe directories:'''
| |
| | |
| *extensions/<MyPDFTemplates>
| |
| *skins/<MyPDFTemplates>
| |
| *images/<MyPDFTemplates>
| |
| *extensions/BlueSpiceFoundation/data/PDFTemplates
| |
| | |
| == Editing the templates ==
| |
| The PDF templates for single pages and books are very similar.
| |
| | |
| === Creating your own templates ===
| |
| The contents of the directories
| |
| | |
| *extensions/BlueSpiceUEModulePDF/data/PDFTempates
| |
| *extensions/BlueSpiceUEModuleBookPDF/data/PDFTempates
| |
| | |
| Copy to "extensions/BlueSpiceFoundation/data/PDFTemplates" and rename it
| |
| | |
| *"common" => "common" (remains)
| |
| *"BlueSpice" => "MyPageTemplate"
| |
| *"BlueSpice Book" => "MyBookTemplate"
| |
| | |
| The template names must be changed later in the associated template.php.
| |
| | |
| === Directory structure of the templates ===
| |
| data/PDFTemplates
| |
| |_ common
| |
| | |_ stylesheets ('''page.css -> Einstellung der Seitenränder''')
| |
| |
| |
| |_ MyPageTemplate
| |
| | |_ template.php
| |
| | |_ template.html
| |
| | |_ images
| |
| | |_ stylesheets ('''styles.css -> Logo in der Kopfzeile''')
| |
| |
| |
| |_ MyBookTemplate
| |
| |_ template.php
| |
| |_ template.html
| |
| |_ images
| |
| |_ stylesheets ('''styles.css -> Logo in der Kopfzeile''')
| |
| | |
| === Customization of the templates ===
| |
| | |
| ==== template.php ====
| |
| The file <code>template.php</code> contains the description or definition of the template. All css files and, if applicable, fonts that are to be used in the template must be specified here.
| |
| | |
| The images must also be specified, for example the images that should be used in the header.
| |
| | |
| | |
| | |
| Special requirements for the book:
| |
| | |
| The PDF template for the book accesses the common directory of the single page template.
| |
| For this reason, the '''template.php''' contains a variable '''$sCommonDir''' that points to the directory. If the templates are copied into their own directory, this path must be adjusted.
| |
| | |
| | |
| | |
| '''Important changes in the sections:'''
| |
| | |
| <u>Section '''info''':</u>
| |
| | |
| *name => name of the template (e.g. MyPageTemplate). '''MUST''' match the directory name
| |
| | |
| <u>Section '''resources''':</u>
| |
| | |
| *STYLESHEETS => if necessary, specify additional style sheets here. These must also be specified in the template.html. If you use other fonts, they must also be specified here.
| |
| *IMAGES => enter the images you want to use here. Example 'images/bs-header.jpg'
| |
| | |
| <u>Section '''messages''':</u>
| |
| | |
| *Here, texts can be assigned to so-called msg keys. These msg keys can be used in the template.html, e.g. the disclaimer.
| |
| *en, de, de-formal are the languages. Unlike texts written in template.html, these msg keys are used depending on the language.
| |
| | |
| ==== template.html ====
| |
| Basic structure of the page. Here, the page number, for example, can be removed from the footer.
| |
| If you want to include your own css files, they must be specified here in the '''<head>'''.
| |
| | |
| Example:
| |
| <link href="stylesheets/styles.css" type="text/css" rel="stylesheet" />
| |
| | |
| === Customization of the style sheets ===
| |
| The display can be changed in the style sheets. This concerns e.g.
| |
| | |
| *Margins
| |
| *Header with logo
| |
| *Headings
| |
| *Text colors
| |
| *...
| |
| | |
| | |
| | |
| <u>'''The most important examples:'''</u>
| |
| | |
| <u>Page margins:</u>
| |
| | |
| '''File:''' common/stylesheets/page.css
| |
| | |
| The '''@page''' area is the normal page in portrait format. The page margins are set in the "margin" line (order: top right bottom left).
| |
| | |
| | |
| | |
| <u>Background image:</u>
| |
| | |
| '''File:''' common/stylesheets/page.css
| |
| | |
| The '''@page''' area is the normal page in portrait format. The background image is set in the “background” line.
| |
| | |
| The background image must be specified in the '''template.php'''. (Only used for the single page at BlueSpice.)
| |
| | |
| | |
| | |
| <u>Header (logo):</u>
| |
| | |
| '''File:''' MyPageTemplate/stylesheets/page.css
| |
| | |
| or
| |
| | |
| '''File:''' MyBookTemplate/stylesheets/page.css
| |
| | |
| With '''#bs-runningheaderfix''', the logo for the header is set in the "background" line.
| |
| | |
| The logo must be specified in the '''template.php'''.
| |
| | |
| The size of the header and logo can be influenced with the parameters “margin”, “background-size” and “height”. The “width” line should remain at 21cm (entire page width).
| |
| | |
| == Configuring the templates ==
| |
| PDF templates cannot be configured via the Wiki.
| |
| | |
| The following lines must be added to LocalSettings.php:
| |
| | |
| *Example for single page:
| |
| | |
| $GLOBALS['bsgUEModulePDFTemplatePath'] = 'extensions/BlueSpiceFoundation/data/PDFTemplates';
| |
| $GLOBALS['bsgUEModulePDFDefaultTemplate'] = 'MyPageTemplate';
| |
| | |
| *Example for book:
| |
| | |
| $GLOBALS['bsgUEModuleBookPDFTemplatePath'] = 'extensions/BlueSpiceFoundation/data
| |
| | |
| [[de:Handbuch:Erweiterung/BlueSpiceUniversalExport/PDF_Vorlagen_erstellen]]
| |