Customised templates: Difference between revisions

m
 
===Editing to create one or more customised templates in the standard web sub-folder===
A number of people have '''reduced the number of web pages by combining templates'''. At time of writing one example of such customisation (combining ''todayT.htm, yesterdayT.htm, thismonthT.htm, and thisyearT.htm'') is visible at [http://tamworthweather.com/today.htm this site]. Some sites combine fewer templates, just yesterday.htm and today.htm at many sites [http://www.cheadlehulmeweather.co.uk/today.htm including this one], and I have seen recordsT.htm combined with other templates.
Other people customise the standard template just to move certain web tags; for example to '''move the monthly total for rainfall''' from ''indexT.htm'' to ''thismonthT.htm'' or to change some of the text shown on a web page to what suits them.
 
As the heading says modify the template files in the ''cumulus\web'' sub-folder, NOT those in 'originals' sub-folder:
*Keep copies of any xxxT.htm files you modify. It is best to back up the whole Cumulus folder onto a different disc on a regular basis.
*Remember to edit the xxxT.htm files, (not the xxx.htm files as they are created by the [[#What is meant by 'Cumulus processes templates' |Cumulus 'process']])
*Keep copies of any xxxT.htm files you modify. It is best to back up the whole Cumulus folder onto a different disc on a regular basis, to save all the files that Cumulus depends upon, not just those it automatically backs up.
*If you edit one or more of the templates, listed in the table above, in the ''cumulus\web'' sub-folder, keeping their original names, this has the advantage that Cumulus will [[#What is meant by 'Cumulus processes templates' |process ]] the customised template as if it is an unmodified standard one.
*You just need to have 'Include Standard Files' ticked (as shown above) on the ''Files'' tab of the '''Internet''' screen within the 'Configuration' menu.
 
*You can modify one or more of the template files listed above. For example, you may wish to
**change the wording that appears on the web page by editing it on the template (e.g. change language or replace "Lowest Wind Chill" with "Greatest Wind Chill" or whatever);
**add a link to another of your pages or externally (e.g. add link to another weather web page);
**add/remove some Cumulus derived information (for example: the monthly rainfall total is on the "index" page, you might want to move it to the "this month" page; and similarly the seasonal rainfall total could be moved from the "index" page to the "this year" page);
**add a page counter; etc
*Remember to edit the xxxT.htm files, (not the xxx.htm files as they are created by the [[#What is meant by 'Cumulus processes templates' |Cumulus 'process']])
*It is best to close down Cumulus while updating the template files.
*You should ideally use a tool designed to help you edit a file written in a 'programming language', although most '''text editor''' tools can be safely used to modify the HTML.
**HTML editors (like [http://notepad-plus.sourceforge.net/uk/site.htm Notepad++], [http://www.htmlkit.com/ HTML kit-292] to cite just two free ones) are just text editors that use colour and other aids to help you identify what you are editing and may make it easier for you as they also preserve the character encoding in the file (the latest Cumulus files are encoded in UTF-8 without BOM - see below).
**Do not use a 'word processor' as that will introduce unwanted characters;
**Avoid most 'web page editors' (like wordpress) as they can change the page structure and remove the Cumulus web tags;
5,838

edits