Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Status
colourYellow
title5.8.0+

...

Any custom images that you wish to use in your Print Templates should reside in the WebApps\WebService\custom\print\templates\images folder and custom css in the WebApps\WebService\custom\print\templates\css folder.

Note
Any images or logos that you add to your template must currently be in .PNG or .SVG format. If the image displays in print preview but not in the pdf output, please verify the file type in a graphics program (don't rely on the file extension).


Tip

If iShare GIS finds any Print Templates in the custom folder then it will ignore any in the base folder so, if you want to use any of those supplied by Astun, you need to copy the ones you want into the custom folder. 


Info

The quickest way to create your own HiDPI Print Templates is to use the QGIS Print Composer to create the Template and then use the iShare GIS Print Template Export plugin.

Below we have the A4-portrait.html which is a Portrait template for printing to A4 size.

...

The page size is controlled by the @page entry. You may create whatever page size you like but the following is a list of the standard paper sizes A1 - A5. The body width & height entries should be less than the page size; by approximately 20mm.

Note
titleUsing an A1 Print Template

If you wish to print using an A1 Print Template, then you will need to add / edit the MAXSIZE parameter in the MapServer MAP Object, in each MyMaps Map Source (.MAP) file that you wish to print to A1 from. This needs to be set to 16384 for printing to A1 successfully.

Example Page Sizes

Page Size

Portrait SizeLandscape Size
A1size: 594mm 841mm;size: 841mm 594mm;
A2size: 420mm 594mm;size: 594mm 420mm;
A3size: 297mm 420mm;size: 420mm 297mm;
A4size: 210mm 297mm;size: 297mm 210mm;
A5size: 148mm 210mm;size: 210mm 148mm;

...

IDValueNotes
mapMapRequired for template to load
legendLegend (when enabled in options)


Excerpt

The following is a list of the Classes that may be used in your HiDPI Print Template.

ClassValueNotes
ishare-user
Current user and domainFormatted as: user@domain
ishare-timestamp
Current timeISO datetime format: e.g. 2018-03-23 14:37:39 
ishare-projection
The in-use map projection codeE.g.: EPSG:27700
ishare-attribution
Copyright taken from the base MapSource
ishare-scale
Current map scale
ishare-centre

ishare-centre-x
ishare-centre-y
Central co-ordinates of the current view of the map

Format for ishare-centre: x, y

Units are rounded to a number of decimal places dependent on the projection units: 5 for degrees; 3 for miles and kilometres; and 0 for everything else.

ishare-bbox

ishare-min-x
ishare-min-y
ishare-max-x
ishare-max-y
Corner co-ordinates of the current view of the map

Format for ishare-bbox: min-x min-y max-x max-y


Units are rounded to a number of decimal places dependent on the projection units: 5 for degrees; 3 for miles and kilometres; and 0 for everything else.


Example

In the above screenshot we have added Projection and Base Map Copyright to the basic A4 Template. To add any Predefined Dynamic elements to your map just extract the details from the following examples:

...