Php webtags: Difference between revisions

3 bytes added ,  09:03, 20 April 2020
m
Line 71: Line 71:
* Another simple template called ''CUtags.txt'' produced by BCJKiwi that works with both Cumulus 1 and MX is at [https://cumulus.hosiene.co.uk/viewtopic.php?f=40&t=17985&p=140688#p140688 this post of mine in a zip], this one does not contain any web tags that are only available in MX, nor does it contain any that require output parameters.
* Another simple template called ''CUtags.txt'' produced by BCJKiwi that works with both Cumulus 1 and MX is at [https://cumulus.hosiene.co.uk/viewtopic.php?f=40&t=17985&p=140688#p140688 this post of mine in a zip], this one does not contain any web tags that are only available in MX, nor does it contain any that require output parameters.
*Another approach is to create an array '''$WX''' that holds a sub-set of Cumulus web tags, choosing some parameter combinations to implement:  
*Another approach is to create an array '''$WX''' that holds a sub-set of Cumulus web tags, choosing some parameter combinations to implement:  
**Using this array your customised pages would replace any reference to a Cumulus web tag '''<#xxyyzz optional_parameter>''' by a PHP array element '''$WX[xxyyzz] [optional_additional_selector]''' (the recent history web tags include for example '''m=10''' as an input parameter, so you select the one you want using the second index).
**Using this array your customised pages would replace any reference to a Cumulus web tag <tt><#xxyyzz optional_parameter></tt> by a PHP array element '''$WX[xxyyzz] [optional_additional_selector]''' (the recent history web tags include for example '''m=10''' as an input parameter, so you select the one you want using the second index).
**A template file to do this is also called ''CUtags.txt'' and it can be downloaded from [http://saratoga-weather.org/wxtemplates/install.php Saratoga-Weather.org].
**A template file to do this is also called ''CUtags.txt'' and it can be downloaded from [http://saratoga-weather.org/wxtemplates/install.php Saratoga-Weather.org].
**That download includes elements for the recent history tags at 5, 10, 15, 20, 30, 45, 60, 75, 90, 105 and 120 minutes. If you want older values or values at other times, then you will need to add these to the array yourself.
**That download includes elements for the recent history tags at 5, 10, 15, 20, 30, 45, 60, 75, 90, 105 and 120 minutes. If you want older values or values at other times, then you will need to add these to the array yourself.
5,838

edits