Cumulus template file: Difference between revisions

From Cumulus Wiki
Jump to navigationJump to search
m
no edit summary
mNo edit summary
mNo edit summary
Consequently, a single template will actually generate a different file each time Cumulus processes that template because the part of the content that was web tags is now populated with text (values, times, dates, etc.) and, as these values change, a newly generated file is different to the previous generated file.
 
==General Format for Web Tags==
 
Typically you would use this to build your own website by having an HTML template file with your layout, static text and graphics. In the position on the page you wish Cumulus to insert the relevant data place a web tag in the '''general format''' specified here: <pre><#tag_name [optional input parameters][optional output parameters]></pre>
==Template files you add==
 
==== Case sensitivity ====
The page dealing with the customisation of web templates is [[Customised templates]], and it includes a diagram that explains how file names are affected by your choices in some of the settings for file transfer.
 
The tag_name in the general format above is case sensitive, so please type the tag name exactly as shown in the web tag columns in the tables on the [Webtags|web tags page]].
People writing their own templates can use any file extension (some popular choices are "tmpl" or "cum" to indicate they are Cumulus templates). To ensure that the template files and generated web pages cannot be confused, Steve Loft realised the "T" notation used by the provided templates may not be part of the name you choose, hence the generated file will have "tmp" added to the end of the template name you selected, just to remind you of its temporary existance until the source template is processed again. That "tmp" is removed when the final web page is stored on your web server.
 
The optional input parameters always use lower case, so please type them exactly as shown in the sections dealing with input parameters on that page.
=== Using web tags in templates for creating HTML pages ===
 
The optional output parameters are case insensitive when used in Cumulus 1. But for Cumulus 2 and later, so this includes MX, the output parameters are case sensitive and also dependent on what other output formatters are being used if any, so please read the sections on output parameters and study the examples in the tables carefully.
You can include special markers in your template file that are called web tags; during processing Cumulus will replace them with the actual values.
 
Typically you would use this to build your own website by having an HTML template file with your layout, static text and graphics. In the position on the page you wish Cumulus to insert the relevant data place a web tag in the general format specified here: <pre><#tag_name [optional input parameters][optional output parameters]></pre>
 
==Template files you add==
''Note: When you put a tag into your template, be careful that whatever program you are using to develop your web pages doesn't change the angle brackets to slightly different symbols -- this is a common cause of failure!'' There are a number of editing tools that are '''designed for editing programming code''' and you should use one of those (e.g. Notepad++, Brackets, NoteTab Light, HTML kit, amongst many others), ''rather than a tool designed for web page design editing'' (e.g. Dreamweaver, word press, amongst others).
 
The page dealing with the customisation of web templates is [[Customised templates]], and it includes a diagram that explains how file names are affected by your choices in some of the settings for file transfer.
 
People writing their own templates can use any file extension (some popular choices are "tmpl" or "cum" to indicate they are Cumulus templates). To ensure that the template files and generated web pages cannot be confused, Steve Loft realised the "T" notation used by the provided templates may not be part of the name you choose, hence the generated file will have "tmp" added to the end of the template name you selected, just to remind you of its temporary existance until the source template is processed again. That "tmp" is removed when the final web page is stored on your web server.
 
''Note: When you put a tag into your template, be careful that whatever program you are using to develop your web pages doesn't change the angle brackets to slightly different symbols -- this is a common cause of failure!'' There are a number of editing tools that are '''designed for editing programming code''' and you should use one of those (e.g. Notepad++, Brackets, NoteTab Light, HTML kit, amongst many others), ''rather than a tool designed for web page design editing'' (e.g. Dreamweaver, word press, amongst others).
==== Case sensitivity ====
 
=== Using web tags in templates for creating HTML pages ===
The tag_name in the general format above is case sensitive, so please type the tag name exactly as shown in the web tag columns in the tables on the [Webtags|web tags page]].
 
You can include special markers in your template file that are called web tags; during processing Cumulus will replace them with the actual values.
The optional input parameters always use lower case, so please type them exactly as shown in the sections dealing with input parameters on that page.
 
Typically you would use this to build your own website by having an HTML template file with your layout, static text and graphics.
The optional output parameters are case insensitive when used in Cumulus 1. But for Cumulus 2 and later, so this includes MX, the output parameters are case sensitive and also dependent on what other output formatters are being used if any, so please read the sections on output parameters and study the examples in the tables carefully.
 
=== Using web tags in scripts ===
5,838

edits

Navigation menu